ambitious-actor-3678105/10/2022, 11:14 AM
to a google artifact registry, but I can with
./pants publish :: 23:12:37.52 [INFO] Completed: Building docker image australia-southeast1-docker.pkg.dev/coneheads-wgtn/containers/web:latest 23:12:37.52 [INFO] Built docker image: australia-southeast1-docker.pkg.dev/coneheads-wgtn/containers/web:latest The push refers to repository [australia-southeast1-docker.pkg.dev/coneheads-wgtn/containers/web] 6ea10f7d4ca8: Preparing 22ada191c158: Preparing 53db6fbe920f: Preparing 315bbfd9d1d9: Preparing 2c7950a1245f: Preparing 9c1b6dd6c1e6: Waiting denied: Permission "artifactregistry.repositories.downloadArtifacts" denied on resource "projects/coneheads-wgtn/locations/australia-southeast1/repositories/containers" (or it may not exist) ✕ australia-southeast1-docker.pkg.dev/coneheads-wgtn/containers/web:latest failed.
docker push australia-southeast1-docker.pkg.dev/coneheads-wgtn/containers/web:latest The push refers to repository [australia-southeast1-docker.pkg.dev/coneheads-wgtn/containers/web] 6ea10f7d4ca8: Pushed 22ada191c158: Pushed 53db6fbe920f: Pushed 315bbfd9d1d9: Pushed 2c7950a1245f: Pushed 9c1b6dd6c1e6: Pushed latest: digest: sha256:0b3ae52304c677a408ff1de287ae5138252a3a3b788279bcfe0620d946a26e6b size: 1582
curved-television-656805/10/2022, 12:39 PM
with any required docker auth plugin scripts.
rapid-exabyte-7668505/11/2022, 4:02 AM
and ultimately, there was some other tool that also needed to be on the path but it wasn’t clear what it was… and various ways of debugging this (explored in that thread) didn’t yield fruit.
[docker] tools = ["gcloud"]
and publishing to GCP Artifact Registry is working for me. However… https://pantsbuild.slack.com/archives/C046T6T9U/p1651129704640679?thread_ts=1651122232.246399&cid=C046T6T9U
[docker] env_vars = [ …, "PATH" ]
curved-television-656805/11/2022, 5:25 AM
hundreds-father-40405/11/2022, 4:25 PM
curved-television-656805/11/2022, 4:26 PM
goal didn’t copy the behavior from the
goal wrgt the chroot placeholder (as the chroot is not known there, as it is not executed in the workspace). The above PR address this, and I’ve now managed to
a docker image to a google cloud registry, using only
hundreds-father-40405/11/2022, 5:42 PM
rapid-exabyte-7668505/11/2022, 10:59 PM
For example, a config file using GCloud might look like this:That is usual established by running the
tool like so…
…with gcloud’s authentication to the GCP project having been established previously… but you’re probably across that and its considered out of scope for the documentation?
gcloud auth configure-docker europe-docker.pkg.dev # With a different registry name if appropriate.
hundreds-father-40405/11/2022, 11:35 PM
rapid-exabyte-7668505/11/2022, 11:35 PM
hundreds-father-40405/12/2022, 3:56 PM
agreeable-oyster-2898105/25/2022, 4:45 PM
curved-television-656805/25/2022, 4:47 PM
agreeable-oyster-2898105/25/2022, 4:50 PM