GoogleCloudPlatform / terraform-google-artifact-registry

Create and manage Artifact Registry repositories
https://registry.terraform.io/modules/GoogleCloudPlatform/artifact-registry/google
Apache License 2.0
11 stars 10 forks source link

FR: registry URL as output #19

Closed pataquets closed 6 months ago

pataquets commented 8 months ago

I'm using the module to deploy a Docker image on Cloud Run. It would be very convenient to have the repo URL europe-west1-docker.pkg.dev/your-project/your-repo/image available as an output for referencing from other locations (in this case, the CR deployed image).

EDIT: Added upstream provider dependency. https://github.com/hashicorp/terraform-provider-google/issues/11355

pataquets commented 6 months ago

@prabhu34 any feedback on this? It would definitely improve module's usability.

prabhu34 commented 6 months ago

@prabhu34 any feedback on this? It would definitely improve module's usability.

There is no output that Terraform knows to get this URL directly. The API doesn't support either. I would recommend to form this URL in the module invocations, based on the GAR ID that is already available as an output, location and name.

Closing this FR.

pataquets commented 6 months ago

@prabhu34 "API doesn't support" means Google Cloud's API or upstream Terraform provider? If the latter, since it's not such a wildly unreasonable feature to expect, I guess it would be better to keep this open until upstream/base Terraform provider implements the output. Additionally, this would be a legitimate FR for the upstream Terraform provider, which would be a dependency for this issue.

pataquets commented 3 weeks ago

@prabhu34 "API doesn't support" means Google Cloud's API or upstream Terraform provider? If the latter, since it's not such a wildly unreasonable feature to expect, I guess it would be better to keep this open until upstream/base Terraform provider implements the output. Additionally, this would be a legitimate FR for the upstream Terraform provider, which would be a dependency for this issue.

@prabhu34 ping?

pataquets commented 1 week ago

Answering to myself by cross-linking to upstream provider issue: hashicorp/terraform-provider-google#11355 @prabhu34: I'd suggest to keep this issue open and easily discoverable to allow affected users to find the relevant upstream issue and let them cast their vote to the most relevant one. Perhaps some "upstream" tag would be in order, thou.