Summary
The user attempted to build and deploy an image to ghcr.io using a specific command but encountered a "403 Forbidden" error related to authorization when trying to save the image. They are using a GitHub token with the necessary permissions but are unsure why the process is failing.
nacho
Just seeing your other messages now...
nacho
Have you authenticated to the ghcr registry? https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-container-registry#authenticating-to-the-container-registry|https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-container-registry#authenticating-t[…]ontainer-registry
kingboscop
I tried to build with earthly and deploy to <http://ghcr.io|ghcr.io>
by doing SAVE IMAGE --push <http://ghcr.io/|ghcr.io/><my-username>/<my-repo-name>:master
, but when running this on my satellite, I get this error:
Build error: failed to SAVE IMAGE: failed to authorize: failed to fetch anonymous token: unexpected status from GET request to <https://ghcr.io/token?scope=repository%3A><my-username>%2F<my-repo-name>%3Apull%2Cpush&service=<http://ghcr.io|ghcr.io>: 403 Forbidden
Even though I'm using a (classic) GitHub token with permissions delete:packages, repo, workflow, write:packages
.
Any idea why it's failing? :slightly_smiling_face: