I have created a new configuration profile using command:
gcloud init
and now I don't know how to switch to old configuration profile without override it.
Using gcloud config
I can't switch to another configuration only set a property of the current configuration.
any idea?
gcloud config list will always show you the properties in your active configuration. To change the active configuration for all commands in your current terminal, you can set the environment variable CLOUDSDK_ACTIVE_CONFIG_NAME to the name of the configuration you'd like to use.
Below is the gcloud info output on my environment, as you can see the configuration files are in User Config Directory: section. In this particular case, you can run gcloud info | grep 'User Config' to list the location of the config files, regardless if you custom install it or not.
Check the available projects by running: gcloud projects list . This will give you a list of projects which you can access. To switch between projects: gcloud config set project <project-id> . Show activity on this post.
You can see your configurations (created via gcloud init) via
gcloud config configurations list
You can switch to a different configuration via
gcloud config configurations activate MY_OLD_CONFIG
Once activated you can
gcloud config list
to see its settings.
You can also do this without activation by running
gcloud config list --configuration CONFIGURATION_NAME
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With