Skip to content
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

Add --only-metadata option to prevent falling back to other ADC sources #14

Merged
merged 1 commit into from
Mar 20, 2024

Conversation

drcapulet
Copy link
Contributor

If running in CI and a step does a GCP login using a different service account, those credentials will get picked up over the node's service which is likelier the preferred account to use since it stays constant.

@drcapulet drcapulet requested a review from a team as a code owner March 20, 2024 22:29
@@ -99,6 +119,7 @@ func parseConfiguration() (*Config, error) {
viper.GetViper().SetDefault("listen", "localhost:8000")

pflag.String("listen", "", "Address for the mirror to listen on.")
pflag.Bool("only-metadata", false, "Only rely upon on the GCE metadata server for authentication.")

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit:

Suggested change
pflag.Bool("only-metadata", false, "Only rely upon on the GCE metadata server for authentication.")
pflag.Bool("only-metadata", false, "Only rely upon the GCE metadata server for authentication.")

If running in CI and a step does a GCP login using a different service
account, those credentials will get picked up over the node's service
which is likelier the preferred account to use since it stays constant.
@drcapulet drcapulet merged commit b3d5d3e into main Mar 20, 2024
2 checks passed
@drcapulet drcapulet deleted the alexc-only-metadata branch March 20, 2024 22:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants