Add initial revision of the ice_lite module to provide basic ICE #135
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Push to DockerHub | |
on: [push, pull_request] | |
env: | |
DOCKER_REPO: sippylabs/rtpproxy | |
PLATFORMS: linux/amd64,linux/i386,linux/arm/v7,linux/arm64 | |
BASE_IMAGE: debian:12-slim | |
jobs: | |
check_disabled_actions: | |
name: Check | |
uses: ./.github/workflows/_check_disabled_actions.yml | |
Docker: | |
name: Build&Push to DockerHub | |
needs: check_disabled_actions | |
if: needs.check_disabled_actions.outputs.should_continue == 'true' | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
with: | |
submodules: 'recursive' | |
- name: Set up QEMU | |
id: qemu | |
uses: docker/setup-qemu-action@v2 | |
with: | |
platforms: arm64,arm | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- name: Log in to Docker Hub | |
if: github.event_name != 'pull_request' | |
uses: docker/login-action@v2 | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Extract metadata (tags, labels) for Docker | |
id: meta | |
uses: docker/metadata-action@v3 | |
with: | |
images: ${{ env.DOCKER_REPO }} | |
tags: | | |
type=schedule | |
type=ref,event=branch | |
type=ref,event=tag | |
type=ref,event=pr | |
type=raw,value=latest,enable={{is_default_branch}} | |
type=sha | |
# Cache the compiler cache | |
- name: Cache the compiler cache | |
uses: actions/cache@v3 | |
with: | |
path: ccache | |
key: dockerhub-ccache-${{ github.run_id }} | |
restore-keys: | | |
dockerhub-ccache | |
- name: Build Docker image | |
uses: docker/build-push-action@v4 | |
with: | |
context: . | |
file: ./docker/Dockerfile | |
build-args: BASE_IMAGE=${{ env.BASE_IMAGE }} | |
tags: | | |
${{ steps.meta.outputs.tags }} | |
labels: ${{ steps.meta.outputs.labels }} | |
platforms: ${{ env.PLATFORMS }} | |
outputs: type=tar,dest=/tmp/ccache_export.tar | |
- name: Push Docker image | |
uses: docker/build-push-action@v4 | |
with: | |
context: . | |
file: ./docker/Dockerfile.push | |
build-args: BASE_IMAGE=${{ env.BASE_IMAGE }} | |
push: true | |
tags: ${{ steps.meta.outputs.tags }} | |
labels: ${{ steps.meta.outputs.labels }} | |
platforms: ${{ env.PLATFORMS }} | |
- name: Update DockerHub repo description | |
if: ${{ github.ref == format('refs/heads/{0}', github.event.repository.default_branch) }} | |
env: | |
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }} | |
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} | |
run: sh -x docker/update_description.sh docker/README.md | |
- name: Extract ccaches | |
run: | | |
rm -rf ccache | |
tar --strip-components=2 --no-wildcards-match-slash --wildcards -x -f /tmp/ccache_export.tar "*/rtpproxy/ccache" | |
du -d1 -h ccache |