ci: Log in to the registry with a write:package token

The automatic Actions token is refused by the container registry
(run 107: unauthorized). Use the REGISTRY_TOKEN repository secret.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
PhilandClaude Opus 5.5 committed 2026-10-31 12:13:43 -06:00
1 parent f46130569f
commit 011f7cc87d
1 file changed
+4 -1
+4 -1
View File
@@ -23,8 +23,11 @@ jobs:
run: apk add --no-cache nodejs git docker-cli docker-cli-buildx
- name: Checkout
uses: actions/checkout@v4
# The automatic Actions token can't log in to the container registry, so
# this uses a personal access token with only the write:package scope,
# stored as the repository secret REGISTRY_TOKEN.
- name: Log in to the Gitea registry
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login "$REGISTRY" -u "${{ github.actor }}" --password-stdin
run: echo "${{ secrets.REGISTRY_TOKEN }}" | docker login "$REGISTRY" -u "${{ github.repository_owner }}" --password-stdin
- name: Use the BuildKit socket
run: docker buildx create --name ci --driver remote "$BUILDKIT" --use
- name: Build and push