From e40dc05c65c1da087f2ff0abd0c183c53fb22b84 Mon Sep 17 00:00:00 2001 From: Philip Peterson <1326208+philip-peterson@users.noreply.github.com> Date: Fri, 30 Oct 2026 05:16:55 -0800 Subject: [PATCH] Throwaway: test the job token against the registry --- .forgejo/workflows/registry-token-test.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .forgejo/workflows/registry-token-test.yml diff --git a/.forgejo/workflows/registry-token-test.yml b/.forgejo/workflows/registry-token-test.yml new file mode 100644 index 00000000..4a5e826f --- /dev/null +++ b/.forgejo/workflows/registry-token-test.yml @@ -0,0 +1,19 @@ +name: Registry token test +# Throwaway: can the built-in job token push to this forge's registry? +on: + push: + branches: [registry-token-test] +jobs: + test: + runs-on: runner-x86-linux + steps: + - name: Push a tiny image with the job token + env: + TOKEN: ${{ secrets.GITHUB_TOKEN }} + ACTOR: ${{ github.actor }} + run: | + podman pull -q docker.io/library/busybox:latest + printf %s "$TOKEN" | podman login forge.quinefoundation.com -u "$ACTOR" --password-stdin + podman tag docker.io/library/busybox:latest forge.quinefoundation.com/quine-global-labs/registry-token-test:1 + podman push forge.quinefoundation.com/quine-global-labs/registry-token-test:1 && echo "RESULT: job token CAN push" || echo "RESULT: job token can NOT push" + podman logout forge.quinefoundation.com || true