indygreg / python-build-standalone

Produce redistributable builds of Python
Mozilla Public License 2.0
1.97k stars 125 forks source link

Variables used for image caching may not be lowercase #182

Closed Edward-Knight closed 1 year ago

Edward-Knight commented 1 year ago

My GitHub username has capitals in, which breaks the new caching for Docker images 🙃

https://github.com/Edward-Knight/python-build-standalone/actions/runs/5646372661/job/15294130051

> Buildx version
/usr/bin/docker buildx build --cache-from type=registry,ref=ghcr.io/indygreg/Edward-Knight/python-build-standalone:build-openssl_3.0 --cache-from type=registry,ref=ghcr.io/indygreg/Edward-Knight/python-build-standalone:build-main --cache-from type=registry,ref=ghcr.io/indygreg/python-build-standalone:build-main --cache-to type=registry,ref=ghcr.io/indygreg/Edward-Knight/python-build-standalone:build-openssl_3.0,ignore-errors=true --file build/build.Dockerfile --iidfile /tmp/docker-actions-toolkit-XMmvH9/iidfile --label org.opencontainers.image.source=https://github.com/Edward-Knight/python-build-standalone --output type=docker,dest=build/image-build.tar --metadata-file /tmp/docker-actions-toolkit-XMmvH9/metadata-file .
ERROR: failed to solve: failed to configure registry cache exporter: invalid reference format: repository name must be lowercase
Error: buildx failed with: ERROR: failed to solve: failed to configure registry cache exporter: invalid reference format: repository name must be lowercase

Introduced in 8c4f568.

Looks like this has bitten quite a few people: https://github.com/orgs/community/discussions/27086, and the workaround isn't super nice: https://github.com/orgs/community/discussions/10553.


Also, the ref=ghcr.io/indygreg/${{ github.repository }} parts looks like they should be ref=ghcr.io/${{ github.repository }}?

Edward-Knight commented 1 year ago

I'll probably submit a PR with a fix tomorrow

indygreg commented 1 year ago

This was fixed in #184.