Skip to content

Commit

Permalink
Add build_test_rtp_io_dock.
Browse files Browse the repository at this point in the history
  • Loading branch information
sobomax committed Oct 7, 2024
1 parent 001e4e7 commit 67a3197
Show file tree
Hide file tree
Showing 2 changed files with 66 additions and 0 deletions.
49 changes: 49 additions & 0 deletions .github/workflows/rtp.io.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,3 +98,52 @@ jobs:
python -m pip install -r requirements.txt
DEBIAN_FRONTEND=noninteractive apt-get install -y gpp
sh -x ./test_run.sh
build_test_rtp_io_dock:
runs-on: ubuntu-latest
env:
BASE_IMAGE: ghcr.io/sippy/rtpproxy:latest
COMPILER: clang-18
BUILD_OS: ubuntu-latest
PYTHON_VERSION: 3.12

steps:
- uses: actions/checkout@v4
with:
submodules: recursive

- name: Checkout VoIPTests repo
uses: actions/checkout@v4
with:
repository: 'sippy/voiptests'
path: dist/voiptests

- name: Checkout RTPProxy repo
uses: actions/checkout@v4
with:
repository: 'sippy/rtpproxy'
path: dist/rtpproxy

- name: Set up QEMU
id: qemu
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Set dynamic environment
run: |
PLATFORMS="`docker manifest inspect ${{ env.BASE_IMAGE }} | \
jq -r '.manifests[] | "\(.platform.os)/\(.platform.architecture)\(if .platform.variant != null then "/\(.platform.variant)" else "" end)"' | \
sort -u | paste -sd ','`"
echo "Platforms: ${PLATFORMS}"
echo "PLATFORMS=${PLATFORMS}" >> $GITHUB_ENV
- name: Build Docker image
uses: docker/build-push-action@v6
with:
context: .
file: ./docker/Dockerfile.rtp.io
build-args: |
BASE_IMAGE=${{ env.BASE_IMAGE }}
platforms: ${{ env.PLATFORMS }}
17 changes: 17 additions & 0 deletions docker/Dockerfile.rtp.io
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# syntax=docker/dockerfile:1.7-labs

ARG BASE_IMAGE="sippylabs/rtpproxy:latest"
FROM --platform=$TARGETPLATFORM $BASE_IMAGE AS build
LABEL maintainer="Maksym Sobolyev <sobomax@sippysoft.com>"

USER root

# Set Environment Variables
ENV DEBIAN_FRONTEND=noninteractive

RUN ls -l /

WORKDIR /tmp

RUN mkdir scripts/build
RUN --mount=type=bind,source=scripts/build,target=scripts/build sh -x build/install_depends.sh

0 comments on commit 67a3197

Please sign in to comment.