cross-rs / cross

“Zero setup” cross compilation and “cross testing” of Rust crates
Apache License 2.0
6.21k stars 354 forks source link

Unable to pull docker images #1508

Closed fosskers closed 1 month ago

fosskers commented 1 month ago

Checklist

Describe your issue

Myself and a colleague on another machine are unable to pull cross's images from GHCR. Both a cross build and a manual docker pull result in errors like:

Unable to find image 'ghcr.io/cross-rs/x86_64-unknown-linux-musl:main' locally
docker: Error response from daemon: Head "https://ghcr.io/v2/cross-rs/x86_64-unknown-linux-musl/manifests/main": denied: denied.

This happens on both our work network and on my home network. Has something recently changed regarding permissions necessary to pull images?

What target(s) are you cross-compiling for?

x86_64-unknown-linux-musl

Which operating system is the host (e.g computer cross is on) running?

What architecture is the host?

What container engine is cross using?

cross version

cross 0.2.5 (19be834 2024-05-17)

Example

> cross build --package hello-world --release --target x86_64-unknown-linux-musl

hello-world is a local test project of ours. The error given is as shown above.

Additional information / notes

No response

fosskers commented 1 month ago

As a workaround, another colleague who still had the image on his machine pushed it to a public location under a different name, which I proceeded to docker pull and retag as what cross was expecting:

> docker tag foo/the-image:main ghcr.io/cross-rs/x86_64-unknown-linux-musl:main
Emilgardis commented 1 month ago

have you logged in to ghcr previously and that token has recently expired? Try reauthing to ghcr.

https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-container-registry#authenticating-to-the-container-registry

fosskers commented 1 month ago

That did it, thank you.