diff options
| author | Mehmet Samet Duman <yongdohyun@projecttick.org> | 2026-04-05 20:59:48 +0300 |
|---|---|---|
| committer | Mehmet Samet Duman <yongdohyun@projecttick.org> | 2026-04-05 20:59:48 +0300 |
| commit | 7e9da79a0df28f875a35c2b5d128e41044c3cd53 (patch) | |
| tree | 8d75eff0cabf414fbb358b6e08725f2613379189 /.github/workflows | |
| parent | 8e281d214b033189abca8e65db581d063e9e82b4 (diff) | |
| download | Project-Tick-7e9da79a0df28f875a35c2b5d128e41044c3cd53.tar.gz Project-Tick-7e9da79a0df28f875a35c2b5d128e41044c3cd53.zip | |
NOISSUE Refactor GitHub Actions and Dockerfiles for improved functionality and error handlingHEADmaster
Signed-off-by: Mehmet Samet Duman <yongdohyun@projecttick.org>
Diffstat (limited to '.github/workflows')
| -rw-r--r-- | .github/workflows/cmark-fuzz.yml | 1 | ||||
| -rw-r--r-- | .github/workflows/images4docker-build.yml | 19 | ||||
| -rw-r--r-- | .github/workflows/meshmc-container.yml | 29 | ||||
| -rw-r--r-- | .github/workflows/neozip-pigz.yml | 2 | ||||
| -rw-r--r-- | .github/workflows/tomlplusplus-fuzz.yml | 1 |
5 files changed, 44 insertions, 8 deletions
diff --git a/.github/workflows/cmark-fuzz.yml b/.github/workflows/cmark-fuzz.yml index 10d2b48ac0..765c1fc496 100644 --- a/.github/workflows/cmark-fuzz.yml +++ b/.github/workflows/cmark-fuzz.yml @@ -23,6 +23,7 @@ jobs: with: oss-fuzz-project-name: 'cmark' dry-run: false + project-src-path: cmark - name: Run Fuzzers uses: google/oss-fuzz/infra/cifuzz/actions/run_fuzzers@master with: diff --git a/.github/workflows/images4docker-build.yml b/.github/workflows/images4docker-build.yml index 36778194bc..92276f65f5 100644 --- a/.github/workflows/images4docker-build.yml +++ b/.github/workflows/images4docker-build.yml @@ -66,14 +66,29 @@ jobs: echo "sha_tag=sha-${short_sha}" >> "$GITHUB_OUTPUT" echo "immutable_tag=${ts}-r${GITHUB_RUN_ID}-a${GITHUB_RUN_ATTEMPT}-${short_sha}" >> "$GITHUB_OUTPUT" - - name: Build and push image + - name: Build image uses: docker/build-push-action@v6 with: context: images4docker file: ${{ matrix.dockerfile }} - push: true + push: false + load: true provenance: false tags: | ghcr.io/project-tick/project-tick/${{ matrix.name }}:latest ghcr.io/project-tick/project-tick/${{ matrix.name }}:${{ steps.tagmeta.outputs.sha_tag }} ghcr.io/project-tick/project-tick/${{ matrix.name }}:${{ steps.tagmeta.outputs.immutable_tag }} + + - name: Push image (with retry) + run: | + push_all() { + docker push "ghcr.io/project-tick/project-tick/${{ matrix.name }}:latest" \ + && docker push "ghcr.io/project-tick/project-tick/${{ matrix.name }}:${{ steps.tagmeta.outputs.sha_tag }}" \ + && docker push "ghcr.io/project-tick/project-tick/${{ matrix.name }}:${{ steps.tagmeta.outputs.immutable_tag }}" + } + for attempt in 1 2 3 4 5; do + push_all && exit 0 + echo "Push attempt $attempt/5 failed, retrying in 30s..." + sleep 30 + done + exit 1 diff --git a/.github/workflows/meshmc-container.yml b/.github/workflows/meshmc-container.yml index 03b88fb0e5..4af5956454 100644 --- a/.github/workflows/meshmc-container.yml +++ b/.github/workflows/meshmc-container.yml @@ -74,15 +74,34 @@ jobs: tags: ${{ steps.image-metadata.outputs.tags }} labels: ${{ steps.image-metadata.outputs.labels }} - - name: Push image - id: push-image + - name: Login to registry if: ${{ github.event_name != 'pull_request' }} - uses: redhat-actions/push-to-registry@v2 + uses: redhat-actions/podman-login@v1 with: - tags: ${{ steps.build-image.outputs.tags }} + registry: ${{ env.REGISTRY }} username: ${{ github.repository_owner }} password: ${{ github.token }} - tls-verify: true + + - name: Push image (with retry) + id: push-image + if: ${{ github.event_name != 'pull_request' }} + run: | + digest="" + while IFS= read -r tag; do + [ -z "$tag" ] && continue + for attempt in 1 2 3 4 5; do + if podman push --tls-verify=true \ + --digestfile="$RUNNER_TEMP/digest.txt" \ + "$tag"; then + digest="$(cat "$RUNNER_TEMP/digest.txt")" + break + fi + [ "$attempt" = 5 ] && exit 1 + echo "Push attempt $attempt/5 failed for $tag, retrying in 30s..." + sleep 30 + done + done <<< "${{ steps.build-image.outputs.tags }}" + echo "digest=$digest" >> "$GITHUB_OUTPUT" - name: Export image digest if: ${{ github.event_name != 'pull_request' }} diff --git a/.github/workflows/neozip-pigz.yml b/.github/workflows/neozip-pigz.yml index e95a25d76b..39b7fb723d 100644 --- a/.github/workflows/neozip-pigz.yml +++ b/.github/workflows/neozip-pigz.yml @@ -42,7 +42,7 @@ jobs: cmake ${{ matrix.cmake-args }} \ -DCMAKE_BUILD_TYPE=Release \ -DBUILD_SHARED_LIBS=OFF \ - -DZLIB_ROOT=../../neozip \ + -DZLIB_ROOT=../.. \ -DWITH_CODE_COVERAGE=OFF \ -DWITH_MAINTAINER_WARNINGS=ON working-directory: neozip/test/pigz diff --git a/.github/workflows/tomlplusplus-fuzz.yml b/.github/workflows/tomlplusplus-fuzz.yml index f326b6301b..bc43e28bbd 100644 --- a/.github/workflows/tomlplusplus-fuzz.yml +++ b/.github/workflows/tomlplusplus-fuzz.yml @@ -24,6 +24,7 @@ jobs: with: oss-fuzz-project-name: 'tomlplusplus' language: c++ + project-src-path: tomlplusplus - name: Run Fuzzers uses: google/oss-fuzz/infra/cifuzz/actions/run_fuzzers@master with: |
