From 1a7a9055e4fa0024810cf1a7f7cfc77a7b5e7532 Mon Sep 17 00:00:00 2001 From: Earl Warren Date: Thu, 17 Oct 2024 06:14:31 +0200 Subject: [PATCH 1/2] forgejo-cli is now a symlink and cannot be used for sanity checks It could be used but then `cp --dereference` would need to be used instead in the forgejo-build-publish action. + docker cp forgejo-amd64:/app/gitea/forgejo-cli forgejo-9.0-test-linux-amd64 + chmod +x forgejo-9.0-test-linux-amd64 chmod: cannot operate on dangling symlink 'forgejo-9.0-test-linux-amd64' --- .forgejo/testdata/build-release/Dockerfile | 2 +- .forgejo/workflows/build-release.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.forgejo/testdata/build-release/Dockerfile b/.forgejo/testdata/build-release/Dockerfile index 9c44dedddd..4ef67d34e0 100644 --- a/.forgejo/testdata/build-release/Dockerfile +++ b/.forgejo/testdata/build-release/Dockerfile @@ -3,4 +3,4 @@ ARG RELEASE_VERSION=unkown LABEL maintainer="contact@forgejo.org" \ org.opencontainers.image.version="${RELEASE_VERSION}" RUN mkdir -p /app/gitea -RUN ( echo '#!/bin/sh' ; echo "echo forgejo v$RELEASE_VERSION" ) > /app/gitea/forgejo-cli ; chmod +x /app/gitea/forgejo-cli +RUN ( echo '#!/bin/sh' ; echo "echo forgejo v$RELEASE_VERSION" ) > /app/gitea/gitea ; chmod +x /app/gitea/gitea diff --git a/.forgejo/workflows/build-release.yml b/.forgejo/workflows/build-release.yml index 4c2905ba4f..177e0ba8b5 100644 --- a/.forgejo/workflows/build-release.yml +++ b/.forgejo/workflows/build-release.yml @@ -170,7 +170,7 @@ jobs: platforms: linux/amd64,linux/arm64,linux/arm/v6 release-notes: "${{ steps.release-notes.outputs.value }}" binary-name: forgejo - binary-path: /app/gitea/forgejo-cli + binary-path: /app/gitea/gitea override: "${{ steps.release-info.outputs.override }}" verify-labels: "maintainer=contact@forgejo.org,org.opencontainers.image.version=${{ steps.release-info.outputs.version }}" verbose: ${{ vars.VERBOSE || secrets.VERBOSE || 'false' }} From 54c8ac3e39fe81f8a9d7ea63c9f1594cccc3220d Mon Sep 17 00:00:00 2001 From: Earl Warren Date: Thu, 17 Oct 2024 06:18:14 +0200 Subject: [PATCH 2/2] vars.SKIP_END_TO_END optionally skip tests when building a release The end-to-end tests will always fail when more than one release is broken. When trying to fix one, the other will get in the way and vice versa. The only way to get out of this deadlock is to replace all broken releases but one by doing the following on forgejo-integration: * set SKIP_END_TO_END to true in the actions vars tab * pushing a commit to the corresponding branch, fixing the problem --- .forgejo/workflows/build-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.forgejo/workflows/build-release.yml b/.forgejo/workflows/build-release.yml index 177e0ba8b5..e894d4c7e9 100644 --- a/.forgejo/workflows/build-release.yml +++ b/.forgejo/workflows/build-release.yml @@ -194,7 +194,7 @@ jobs: verbose: ${{ vars.VERBOSE || secrets.VERBOSE || 'false' }} - name: end-to-end tests - if: ${{ secrets.TOKEN != '' && vars.ROLE == 'forgejo-integration' }} + if: ${{ secrets.TOKEN != '' && vars.ROLE == 'forgejo-integration' && vars.SKIP_END_TO_END != 'true' }} uses: https://code.forgejo.org/actions/cascading-pr@v2 with: origin-url: ${{ env.GITHUB_SERVER_URL }}