chore: Build a docker image with coverage info in it.

We can then use that to build a coverage web UI on render.com using the
Dockerfile.nginx build.
This commit is contained in:
iphydf 2023-12-22 00:18:59 +00:00
parent 415cb78f5e
commit 572924e924
No known key found for this signature in database
GPG Key ID: 3855DBA2D74403C9
2 changed files with 32 additions and 4 deletions

View File

@ -9,8 +9,35 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
- name: Docker Build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v4
with:
file: other/docker/alpine-s390x/Dockerfile
docker-coverage:
runs-on: ubuntu-latest
steps:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
with:
driver: docker
- name: Login to DockerHub
if: ${{ github.event_name == 'push' }}
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build toxchat/c-toxcore:sources
uses: docker/build-push-action@v4
with:
file: other/docker/sources/Dockerfile
tags: toxchat/c-toxcore:sources
- name: Build and push
uses: docker/build-push-action@v4
with:
file: other/docker/coverage/Dockerfile
push: ${{ github.event_name == 'push' }}
tags: toxchat/c-toxcore:coverage
cache-from: type=registry,ref=toxchat/c-toxcore:coverage
cache-to: type=inline

View File

@ -19,13 +19,14 @@ jobs:
SONAR_SERVER_URL: "https://sonarcloud.io"
BUILD_WRAPPER_OUT_DIR: build_wrapper_output_directory # Directory where build-wrapper output will be placed
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
submodules: recursive
- name: Set up JDK 17
uses: actions/setup-java@v1
uses: actions/setup-java@v2
with:
distribution: "zulu"
java-version: 17
- name: Download and set up sonar-scanner
env: