Manage gdcloud CLI properties

Properties are settings that govern the behavior of the gdcloud CLI.

You can use properties to define settings on an organization and/or a project context such as the organization console URL and project used by the gdcloud CLI for authentication, the information to use when working with the Disaster Recovery service, or the option to turn off automatic gdcloud CLI component update checks. For more details about organization and project context, see View and switch context. Properties can also be used to define gdcloud CLI preferences like accessibility configuration for gdcloud CLI commands.

Properties and flags

The gdcloud CLI supports command flags that have the same effect as gdcloud CLI properties. Properties allow you to maintain the same settings across command executions while flags affect command behavior on a per-invocation basis. Note that flags override properties when both are set.

Configurations

A configuration is a named set of gdcloud CLI properties. The gdcloud CLI uses a configuration named default as the initial active configuration. The default configuration is suitable for most use cases. However, you can also create additional configurations and switch between them as required.

List properties

To list the properties in the active configuration, run:

gdcloud config list

Set properties

To set a property in the active configuration, run gdcloud config set. The following example sets the project property, where PROJECT_ID is the unique ID for your project.

gdcloud config set project PROJECT_ID

To set properties that are not in the core properties section, you must specify the section followed by a forward slash before the property name. The following example sets the login_config_cert_path property:

gdcloud config set auth/login_config_cert_path CA_CERT_PATH

Replace the CA_CERT_PATH variable with the path of your Certificate Authority (CA) certificate. For example, /tmp/web-tls-ca.cert.

Available properties

The list of all properties can be found by running gdcloud topic configurations command and looking for the Available Properties section.