Throwaway: test the job token against the registry
All checks were successful
Registry token test / test (push) Successful in 3s
All checks were successful
Registry token test / test (push) Successful in 3s
This commit is contained in:
parent
12ef486714
commit
e40dc05c65
1 changed files with 19 additions and 0 deletions
19
.forgejo/workflows/registry-token-test.yml
Normal file
19
.forgejo/workflows/registry-token-test.yml
Normal file
|
|
@ -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
|
||||
Loading…
Reference in a new issue