-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature request: Automatically attempt to get Google Project if not set #489
Comments
@drzero42 would you be willing to contribute a PR? |
@hjacobs I'll give it a try - not the most experienced Go-programmer, so will probably need some guidance for some things. |
@drzero42 Good idea. Instead of making the HTTP calls yourself I think you can use Google's Keep in mind that there are people that manage their Google DNS records in another project as well as people managing a Google domain from a cluster running somewhere else. This could also help: https://godoc.org/cloud.google.com/go/compute/metadata#OnGCE |
@linki Yeah, I was thinking that Google would probably have a Go library to handle it. I'll look into using that. |
* Add util to assert correct krew setup Homebrew refuses to add a post-install message for setting up the PATH variable with krew's plugin store. Therefore we need to check this on our side to warn users about an incomplete setup. The goal is to - print specific instructions for each shell/OS. - not print the instructions when krew installs itself. * Comments
My use-case:
I currently run external-dns in my clusters with a deployment that uses this argument:
--google-project=$(GOOGLE_PROJECT)
It sets the env variable from a configmap that is populated by Terraform, when the cluster is created.
This makes it possible for me to reuse the same yaml-file for all of my clusters.
I would however like to deploy at least the standard components on my clusters with Helm, and the Helm chart does not allow me to set envs based on configmaps not created by the chart, so I have to tell the Helm chart the Google Project at deploy time.
This can of cause be fixed in the chart, but it would be really nice, if external-dns would attempt to find the Google Project on it's own, if the provider is specified to be Google, and no Project is given.
This is a fairly easy thing to do, you just need to do an HTTP GET on http://metadata.google.internal/computeMetadata/v1/project/project-id with this header set: "Metadata-Flavor: Google".
The text was updated successfully, but these errors were encountered: