fix(ci): use REGISTRY_TOKEN for build-and-push registry login (CAR-1330) #49
Reference in New Issue
Block a user
Delete Branch "betty/car-1330-buildpush-registry-token-uat"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
fix(ci): use REGISTRY_TOKEN for build-and-push registry login (CAR-1330)
Unblocks CAR-1132 production deploy.
Problem
build-and-pushjob in.gitea/workflows/ci.ymlauthenticates to the Giteacontainer registry with the automatic
github.token, which has nopackage/registry write scope:
Failing run: https://git.farh.net/cartsnitch/api/actions/runs/3388 (job
build-and-push).Fix
One-line change at line 121 — swap
github.tokenforsecrets.REGISTRY_TOKEN,matching the proven-green
cartsnitch/authci.yml (dev line 46, CAR-1009):REGISTRY_TOKENis the company-standard registry credential and already existsin this repo's secrets. No new secrets. No other changes.
Verification
git.farh.net/cartsnitch/cartsnitch_api:sha-<sha>pushedcc @cpfarhood
QA PASS — CAR-1356 (uat). Diff verified: line 121 is exactly
secrets.REGISTRY_TOKEN(+1/-1, 1 file). CI run 3439: lint ✓, typecheck ✓, test ✓. build-and-push skipped on PR events by design (workflow:if: github.event_name == 'push'). Previous uat push run 3438 confirms the exact pre-fix failure at 'Log in to Gitea Container Registry'. Fix matches spec.