Thanks for providing the docker image and guide for cleaning up gcr images, really appreciate it!
It took me some time to figure out how to make gcr-cleaner work with images that are hosted on eu.gcr.io.
I thought it might be helpful to share this for others who are using regions other than us:
Change gs://.artifacts.{PROJECT_ID}.appspot.com to gs://${ARTIFACTS_REGION}.artifacts.{PROJECT_ID}.appspot.com, where ${ARTIFACTS_REGION} is replaced with your region, e.g. eu.
The path to the registry containers (aka repo) must include the region too. ${ARTIFACTS_REGION}.gcr.io/${PROJECT_ID}/${REPO_NAME}/${IMAGE_NAME}"
I've created a shell script with which you have to only replace the variables at the top of the file and then run it. It supports defining multiple images under the same repository. Find the gist here
Thanks for providing the docker image and guide for cleaning up gcr images, really appreciate it!
It took me some time to figure out how to make
gcr-cleaner
work with images that are hosted oneu.gcr.io
.I thought it might be helpful to share this for others who are using regions other than
us
:gs://.artifacts.{PROJECT_ID}.appspot.com
togs://${ARTIFACTS_REGION}.artifacts.{PROJECT_ID}.appspot.com
, where ${ARTIFACTS_REGION} is replaced with your region, e.g.eu
.repo
) must include the region too.${ARTIFACTS_REGION}.gcr.io/${PROJECT_ID}/${REPO_NAME}/${IMAGE_NAME}"
I've created a shell script with which you have to only replace the variables at the top of the file and then run it. It supports defining multiple images under the same repository. Find the gist here