gcloud config set Stay organized with collections Save and categorize content based on your preferences.
- NAME
- gcloud config set - set a Google Cloud CLI property
- SYNOPSIS
gcloud config setSECTION/PROPERTYVALUE[--installation][GCLOUD_WIDE_FLAG …]
- DESCRIPTION
- gcloud config set sets the specified property in your active configuration only.A property governs the behavior of a specific aspect of Google Cloud CLI such asthe service account to use or the verbosity level of logs. To set the propertyacross all configurations, use the
--installationflag. For moreinformation regarding creating and using configurations, seegcloud topicconfigurations.To view a list of properties currently in use, run
gcloud config list.To unset properties, use
gcloud config unset.Google Cloud CLI comes with a
defaultconfiguration. To createmultiple configurations, usegcloud configconfigurations create, andgcloud configconfigurations activateto switch between them.Note: If you are using Cloud Shell, your gcloud command-line tool preferencesare stored in a temporary
tmpfolder, set for your current tabonly, and do not persist across sessions. For details on how to make theseconfigurations persist, refer to the Cloud Shell guide on setting gcloudcommand-line tool preferences:https://cloud.google.com/shell/docs/configuring-cloud-shell#gcloud_command-line_tool_preferences. - EXAMPLES
- To set the
projectproperty in the core section, run:gcloudconfigsetprojectPROJECT_IDTo set the
zoneproperty in thecomputesection, run:gcloudconfigsetcompute/zoneZONE_NAMETo disable prompting for scripting, run:
gcloudconfigsetdisable_promptstrueTo set a proxy with the appropriate type, and specify the address and port onwhich to reach it, run:
gcloudconfigsetproxy/typehttpgcloudconfigsetproxy/address1.234.56.78gcloudconfigsetproxy/port8080For a full list of accepted values, seehttps://cloud.google.com/sdk/gcloud/reference/topic/configurations#AVAILABLE-PROPERTIES.
- POSITIONAL ARGUMENTS
SECTION/PROPERTY- Property to be set. Note that SECTION/ is optional while referring to propertiesin the core section, i.e., using either
core/projectorprojectis a valid way of setting a project. Using section names isrequired for setting other properties likecompute/region. Consultthe Available Properties section below for a comprehensive list of properties. VALUE- Value to be set.
- FLAGS
--installation- If set, the property is updated for the entire Google Cloud CLI installation.Otherwise, by default, the property is updated only in the currently activeconfiguration.
- GCLOUD WIDE FLAGS
- These flags are available to all commands:
--access-token-file,--account,--billing-project,--configuration,--flags-file,--flatten,--format,--help,--impersonate-service-account,--log-http,--project,--quiet,--trace-token,--user-output-enabled,--verbosity.Run
$gcloud helpfor details. - AVAILABLE PROPERTIES
coreaccount- Account
gcloudshould use forauthentication. Rungcloud authlistto see your currently available accounts. console_log_format- Control the format used to display log messages to the console.
Valid values are:
standard- Simplified log messages are displayed on the console.detailed- More detailed messages are displayed on the console.
If unset, default is
standard. custom_ca_certs_file- Absolute path to a custom CA cert file.
default_format- Sets the default format for printing command resources.
core/default_formatoverrides the default yaml format. If thecommand contains a command-specific output format, it takes precedence over thecore/default_formatvalue. Use--verbosity=debugflagto view the command-specific format. Bothcore/formatand--formatalso take precedence overcore/default_format. The supported formats are limited to:config,default,disable,flattened,json,list,none,object,text. For more details run $gcloud topic formats. Run$gcloud config set --helpto see moreinformation aboutcore/default_format default_regional_backend_service- If True, backend services in
gcloud computebackend-serviceswill be regional by default. Setting the--globalflag is required for global backend services. disable_color- If True, color will not be used when printing messages in the terminal.
disable_file_logging- If True,
gcloudwill not storelogs to a file. This may be useful if disk space is limited. disable_prompts- If True, the default answer will be assumed for all user prompts. However, forany prompts that require user input, an error will be raised. This is equivalentto either using the global
--quietflag or setting the environmentvariableCLOUDSDK_CORE_DISABLE_PROMPTSto 1. Setting this propertyis useful when scripting withgcloud. disable_usage_reporting- If True, anonymous statistics on SDK usage will not be collected. This value isset by your choices during installation, but can be changed at any time. Formore information, seeUsagestatistics.
format- Sets the format for printing all command resources. This overrides the defaultcommand-specific human-friendly output format. Use
--verbosity=debugflag to view the command-specific format. If bothcore/default_formatandcore/formatare specified,core/formattakes precedence. If bothcore/formatand--formatare specified,--formattakes precedence. Thesupported formats are limited to:config,default,disable,flattened,json,list,none,object,text.For more details run $gcloudtopic formats. Run$gcloudconfig set --helpto see more information aboutcore/format log_http- If True, log HTTP requests and responses to the logs. To see logs in theterminal, adjust
verbositysettings. Otherwise, logs are availablein their respective log files. max_log_days- Maximum number of days to retain log files before deleting. If set to 0, turnsoff log garbage collection and does not delete log files. If unset, the defaultis 30 days.
parse_error_details- If True,
gcloudwill attempt toparse and interpret error details in API originating errors. If False,gcloudwill write flush error details asis to stderr/log. pass_credentials_to_gsutil- If True, pass the configured Google Cloud CLI authentication to gsutil.
project- Project ID of the Cloud Platform project to operate on by default. This can beoverridden by using the global
--projectflag. show_structured_logs- Control when JSON-structured log messages for the current verbosity level (andabove) will be written to standard error. If this property is disabled, logs areformatted as
textby default.Valid values are:
never- Log messages as textalways- Always log messages as JSONlog- Only log messages as JSON if stderr is a fileterminal- Only log messages as JSON if stderr is a terminal
If unset, default is
never. trace_token- Token used to route traces of service requests for investigation of issues. Thistoken will be provided by Google support.
universe_domain- Sets the domain of the universe to use for API requests.
user_output_enabled- True, by default. If False, messages to the user and command output on bothstandard output and standard error will be suppressed.
verbosity- Default logging verbosity for
gcloudcommands. This is the equivalentof using the global--verbosityflag. Supported verbosity levels:debug,info,warning,error,critical, andnone.
accessibilityscreen_reader- Make gcloud more screen reader friendly.
airegion- Default region to use when working with AI Platform resources. When a
--regionflag is required but not provided, the command will fallback to this value, if set.
ai_platformregion- Default region to use when working with AI Platform Training and Predictionresources (currently for Prediction only). It is ignored for training resourcesfor now. The value should be either
globalor one of the supportedregions. When a--regionflag is required but not provided, thecommand will fall back to this value, if set.
api_endpoint_overridesaccessapproval- Overrides API endpoint for
gcloud access-approvalcommand group. Defaults tohttps://accessapproval.googleapis.com/ accesscontextmanager- Overrides API endpoint for
gcloudaccess-context-managercommand group. Defaults tohttps://accesscontextmanager.googleapis.com/ ai- Overrides API endpoint for
gcloudaicommand group. aiplatform- Overrides API endpoint for
gcloud ai-platformcommandgroup. Defaults tohttps://aiplatform.googleapis.com/ anthosevents- Overrides API endpoint for
gcloudanthoscommand group. Defaults tohttps://anthosevents.googleapis.com/ anthospolicycontrollerstatus_pa- Overrides API endpoint for
gcloud containerfleet policycontrollercommand group. Defaults tohttps://anthospolicycontrollerstatus-pa.googleapis.com/ apigateway- Overrides API endpoint for
gcloud api-gatewaycommandgroup. Defaults tohttps://apigateway.googleapis.com/ apigee- Overrides API endpoint for
gcloudapigeecommand group. Defaults tohttps://apigee.googleapis.com/ appengine- Overrides API endpoint for
gcloudappcommand group. Defaults tohttps://appengine.googleapis.com/ apphub- Overrides API endpoint for
gcloudapphubcommand group. Defaults tohttps://apphub.googleapis.com/ artifactregistry- Overrides API endpoint for
gcloud artifactscommandgroup. Defaults tohttps://artifactregistry.googleapis.com/ assuredworkloads- Overrides API endpoint for
gcloudassuredcommand group. Defaults tohttps://assuredworkloads.googleapis.com/ auditmanager- Overrides API endpoint for
gcloud audit-managercommand group. Defaults tohttps://auditmanager.googleapis.com/ baremetalsolution- Overrides API endpoint for
gcloudbmscommand group. Defaults tohttps://baremetalsolution.googleapis.com/ bigtableadmin- Overrides API endpoint for
gcloudbigtablecommand group. Defaults tohttps://bigtableadmin.googleapis.com/ certificatemanager- Overrides API endpoint for
gcloudcertificate-managercommand group. Defaults tohttps://certificatemanager.googleapis.com/ cloudasset- Overrides API endpoint for
gcloudassetcommand group. Defaults tohttps://cloudasset.googleapis.com/ cloudbilling- Overrides API endpoint for
gcloudbillingcommand group. Defaults tohttps://cloudbilling.googleapis.com/ cloudbuild- Overrides API endpoint for
gcloudbuildscommand group. Defaults tohttps://cloudbuild.googleapis.com/ cloudcommerceconsumerprocurement- Overrides API endpoint for
gcloud commerce-procurementcommandgroup. Defaults tohttps://cloudcommerceconsumerprocurement.googleapis.com/ clouddebugger- Overrides API endpoint for
gcloud debugcommand group. Defaults tohttps://clouddebugger.googleapis.com/ clouddeploy- Overrides API endpoint for
gclouddeploycommand group. Defaults tohttps://clouddeploy.googleapis.com/ clouderrorreporting- Overrides API endpoint for
gcloud error-reportingcommand group.Defaults tohttps://clouderrorreporting.googleapis.com/ cloudfunctions- Overrides API endpoint for
gcloud functionscommandgroup. Defaults tohttps://cloudfunctions.googleapis.com/ cloudidentity- Overrides API endpoint for
gcloudidentitycommand group. Defaults tohttps://cloudidentity.googleapis.com/ cloudkms- Overrides API endpoint for
gcloudkmscommand group. Defaults tohttps://cloudkms.googleapis.com/ cloudlocationfinder- Overrides API endpoint for
gcloudcloudlocationfindercommand group. Defaults tohttps://cloudlocationfinder.googleapis.com/ cloudresourcemanager- Overrides API endpoint for
gcloudprojectscommand group. Defaults tohttps://cloudresourcemanager.googleapis.com/ cloudscheduler- Overrides API endpoint for
gcloud schedulercommandgroup. Defaults tohttps://cloudscheduler.googleapis.com/ cloudsecuritycompliance- Overrides API endpoint for
gcloudcompliance-managercommand group. Defaults tohttps://cloudsecuritycompliance.googleapis.com/ cloudtasks- Overrides API endpoint for
gcloudtaskscommand group. Defaults tohttps://cloudtasks.googleapis.com/ cloudtrace- Overrides API endpoint for
gcloud tracecommand group. Defaults tohttps://cloudtrace.googleapis.com/ composer- Overrides API endpoint for
gcloudcomposercommand group. Defaults tohttps://composer.googleapis.com/ compute- Overrides API endpoint for
gcloudcomputecommand group. For Private Service Connect usage, seehttps://cloud.google.com/vpc/docs/configure-private-service-connect-apis#using-endpoints config- Overrides API endpoint for
gcloud infra-managercommand group. Defaults tohttps://config.googleapis.com/ container- Overrides API endpoint for
gcloud containercommandgroup. Defaults tohttps://container.googleapis.com/ datacatalog- Overrides API endpoint for
gcloud data-catalogcommandgroup. Defaults tohttps://datacatalog.googleapis.com/ dataflow- Overrides API endpoint for
gclouddataflowcommand group. Defaults tohttps://dataflow.googleapis.com/ datafusion- Overrides API endpoint for
gcloud data-fusioncommand group.Defaults tohttps://datafusion.googleapis.com/ datamigration- Overrides API endpoint for
gclouddatabase-migrationcommand group. Defaults tohttps://datamigration.googleapis.com/ datapipelines- Overrides API endpoint for
gcloud datapipelinescommand group.Defaults tohttps://datapipelines.googleapis.com/ dataplex- Overrides API endpoint for
gclouddataplexcommand group. Defaults tohttps://dataplex.googleapis.com/ dataproc- Overrides API endpoint for
gclouddataproccommand group. Defaults tohttps://dataproc.googleapis.com/ datastore- Overrides API endpoint for
gcloud datastorecommandgroup. Defaults tohttps://datastore.googleapis.com/ datastream- Overrides API endpoint for
gcloud datastreamcommandgroup. Defaults tohttps://datastream.googleapis.com/ deploymentmanager- Overrides API endpoint for
gclouddeployment-managercommand group. Defaults tohttps://deploymentmanager.googleapis.com/ developerconnect- Overrides API endpoint for
gclouddeveloper-connectcommand group. Defaults tohttps://developerconnect.googleapis.com/ dns- Overrides API endpoint for
gclouddnscommand group. Defaults tohttps://dns.googleapis.com/dns/v1/ domains- Overrides API endpoint for
gclouddomainscommand group. Defaults tohttps://domains.googleapis.com/ edgecontainer- Overrides API endpoint for
gcloud edge-containercommand group.Defaults tohttps://edgecontainer.googleapis.com/ eventarc- Overrides API endpoint for
gcloudeventarccommand group. Defaults tohttps://eventarc.googleapis.com/ eventarcpublishing- Overrides API endpoint for
gcloud eventarc publishcommand group.Defaults tohttps://eventarcpublishing.googleapis.com/ faultinjectiontesting- Overrides API endpoint for
gcloud fault-injectioncommand group.Defaults tohttps://faultinjectiontesting.googleapis.com/ faulttesting- Overrides API endpoint for
gcloud fault-testingcommand group.Defaults tohttps://faulttesting.googleapis.com/ file- Overrides API endpoint for
gcloud filestorecommandgroup. Defaults tohttps://file.googleapis.com/ firebasedataconnect- Overrides API endpoint for
gcloud firebase-data-connectcommandgroup. Defaults tohttps://firebasedataconnect.googleapis.com/ firestore- Overrides API endpoint for
gcloud firestorecommandgroup. Defaults tohttps://firestore.googleapis.com/ genomics- Overrides API endpoint for
gcloud genomicscommand group. Defaultstohttps://genomics.googleapis.com/ gkemulticloud- Overrides API endpoint for
gcloud container aws,gcloud containerazureandgcloud containerattachedcommand groups. healthcare- Overrides API endpoint for
gcloud healthcarecommandgroup. Defaults tohttps://healthcare.googleapis.com/ hypercomputecluster- Overrides API endpoint for
gcloud cluster-directorcommand group.Defaults tohttps://hypercomputecluster.googleapis.com/ iam- Overrides API endpoint for
gcloudiamcommand group. Defaults tohttps://iam.googleapis.com/ iamcredentials- Overrides API endpoint for
gcloudiamcommand group. Defaults tohttps://iamcredentials.googleapis.com/ iap- Overrides API endpoint for
gcloudiapcommand group. Defaults tohttps://iap.googleapis.com/ ids- Overrides API endpoint for
gcloudidscommand group. Defaults tohttps://ids.googleapis.com/ krmapihosting- Overrides API endpoint for
gcloud anthos configcontrollercommand group. Defaults tohttps://krmapihosting.googleapis.com/ language- Overrides API endpoint for
gcloud ml languagecommandgroup. Defaults tohttps://language.googleapis.com/ lifesciences- Overrides API endpoint for
gcloud lifesciencescommand group.Defaults tohttps://lifesciences.googleapis.com/ logging- Overrides API endpoint for
gcloudloggingcommand group. Defaults tohttps://logging.googleapis.com/ looker- Overrides API endpoint for
gcloudlookercommand group. Defaults tohttps://looker.googleapis.com/ managedidentities- Overrides API endpoint for
gcloud active-directorycommand group. Defaults tohttps://managedidentities.googleapis.com/ marketplacesolutions- Overrides API endpoint for
gcloud mpscommand group. Defaults tohttps://marketplacesolutions.googleapis.com/ mediaasset- Overrides API endpoint for
gcloud mediacommand group. Defaults tohttps://mediaasset.googleapis.com/ memcache- Overrides API endpoint for
gcloudmemcachecommand group. Defaults tohttps://memcache.googleapis.com/ metastore- Overrides API endpoint for
gcloud metastorecommandgroup. Defaults tohttps://metastore.googleapis.com/ monitoring- Overrides API endpoint for
gcloud monitoringcommandgroup. Defaults tohttps://monitoring.googleapis.com/ netapp- Overrides API endpoint for
gcloudnetappcommand group. Defaults tohttps://netapp.googleapis.com/ networkconnectivity- Overrides API endpoint for
gcloudnetwork-connectivitycommand group. Defaults tohttps://networkconnectivity.googleapis.com/ networkmanagement- Overrides API endpoint for
gcloudnetwork-managementcommand group. Defaults tohttps://networkmanagement.googleapis.com/ networksecurity- Overrides API endpoint for
gcloud network-securitycommand group. Defaults tohttps://networksecurity.googleapis.com/ networkservices- Overrides API endpoint for
gcloud network-servicescommand group. Defaults tohttps://networkservices.googleapis.com/ notebooks- Overrides API endpoint for
gcloud notebookscommandgroup. Defaults tohttps://notebooks.googleapis.com/ observability- Overrides API endpoint for
gcloud observabilitycommand group. Defaults tohttps://observability.googleapis.com/ orgpolicy- Overrides API endpoint for
gcloud org-policiescommandgroup. Defaults tohttps://orgpolicy.googleapis.com/ policyanalyzer- Overrides API endpoint for
policy-intelligencecommand group.Defaults tohttps://policyanalyzer.googleapis.com/ privateca- Overrides API endpoint for
gcloud privatecacommandgroup. Defaults tohttps://privateca.googleapis.com/ privilegedaccessmanager- Overrides API endpoint for
gcloudpamcommand group. Defaults tohttps://privilegedaccessmanager.googleapis.com/ publicca- Overrides API endpoint for
gcloudpubliccacommand group. Defaults tohttps://publicca.googleapis.com/ pubsub- Overrides API endpoint for
gcloudpubsubcommand group. Defaults tohttps://pubsub.googleapis.com/ recaptchaenterprise- Overrides API endpoint for
gcloud recaptchacommandgroup. Defaults tohttps://recaptchaenterprise.googleapis.com/ recommender- Overrides API endpoint for
gcloud recommendercommandgroup. Defaults tohttps://recommender.googleapis.com/ redis- Overrides API endpoint for
gcloudrediscommand group. Defaults tohttps://redis.googleapis.com/ run- Overrides API endpoint for
gcloudruncommand group. Defaults tohttps://run.googleapis.com/ runtimeconfig- Overrides API endpoint for
gcloud runtime-configcommand group.Defaults tohttps://runtimeconfig.googleapis.com/ sddc- Overrides API endpoint for
gcloud vmware sddccommand group.Defaults tohttps://sddc.googleapis.com/ secretmanager- Overrides API endpoint for
gcloudsecretscommand group. Defaults tohttps://secretmanager.googleapis.com/ securitycenter- Overrides API endpoint for
gcloudscccommand group. Defaults tohttps://securitycenter.googleapis.com/ servicedirectory- Overrides API endpoint for
gcloudservice-directorycommand group. Defaults tohttps://servicedirectory.googleapis.com/ servicemanagement- Overrides API endpoint for
gcloud endpointscommandgroup. Defaults tohttps://servicemanagement.googleapis.com/ sourcerepo- Overrides API endpoint for
gcloudsourcecommand group. Defaults tohttps://sourcerepo.googleapis.com/ spanner- Overrides API endpoint for
gcloudspannercommand group. For spanner emulator usage, seehttps://cloud.google.com/spanner/docs/emulator#using_the_gcloud_cli_with_the_emulator speech- Overrides API endpoint for
gcloud ml speechcommandgroup. Defaults tohttps://speech.googleapis.com/ sql- Overrides API endpoint for
gcloudsqlcommand group. storage- Overrides API endpoint for
gcloudstoragecommand group. Defaults tohttps://storage.googleapis.com/storage/v1/ testing- Overrides API endpoint for
gcloud firebase testcommand group. Defaults tohttps://testing.googleapis.com/ transfer- Overrides API endpoint for
gcloudtransfercommand group. transferappliance- Overrides API endpoint for
gcloud transfer appliancescommandgroup. Defaults tohttps://transferappliance.googleapis.com/ vision- Overrides API endpoint for
gcloud ml visioncommandgroup. Defaults tohttps://vision.googleapis.com/ vmmigration- Overrides API endpoint for
gcloud migration vmscommand group. Defaults tohttps://vmmigration.googleapis.com/ vmwareengine- Overrides API endpoint for
gcloudvmwarecommand group. Defaults tohttps://vmwareengine.googleapis.com/ workflowexecutions- Overrides API endpoint for
gcloud workflowsexecutionscommand group. Defaults tohttps://workflowexecutions.googleapis.com/ workflows- Overrides API endpoint for
gcloud workflowscommandgroup. Defaults tohttps://workflows.googleapis.com/ workstations- Overrides API endpoint for
gcloud workstationscommandgroup. Defaults tohttps://workstations.googleapis.com/
appcloud_build_timeout- Timeout, in seconds, to wait for Docker builds to complete during deployments.All Docker builds now use the Cloud Build API.
promote_by_default- If True, when deploying a new version of a service, that version will bepromoted to receive all traffic for the service. This property can be overriddenwith the
--promote-by-defaultor--no-promote-by-defaultflags. stop_previous_version- If True, when deploying a new version of a service, the previously deployedversion is stopped. If False, older versions must be stopped manually.
use_runtime_builders- If set, opt in/out to a new code path for building applications usingpre-fabricated runtimes that can be updated independently of client tooling. Ifnot set, the default path for each runtime is used.
artifactslocation- Default location to use when working with Artifact Registry resources. When a
locationvalue is required but not provided, the command will fallback to this value, if set. If this value is unset, the default location isglobalwhenlocationvalue is optional. repository- Default repository to use when working with Artifact Registry resources. When a
repositoryvalue is required but not provided, the command willfall back to this value, if set.
authaccess_token_file- A file path to read the access token. Use this property to authenticate gcloudwith an access token. The credentials of the active account (if it exists) willbe ignored. The file should contain an access token with no other information.
disable_credentials- If True,
gcloudwill notattempt to load any credentials or authenticate any requests. This is usefulwhen behind a proxy that adds authentication to requests. impersonate_service_account- While set, all API requests will be made as the given service account or targetservice account in an impersonation delegation chain instead of the currentlyselected account. You can specify either a single service account as theimpersonator, or a comma-separated list of service accounts to create animpersonation delegation chain. This is done without needing to create,download, or activate a key for the service account or accounts.
In order to make API requests as a service account, your currently selectedaccount must have an IAM role that includes the
iam.serviceAccounts.getAccessTokenpermission for the serviceaccount or accounts.The
roles/iam.serviceAccountTokenCreatorrole has theiam.serviceAccounts.getAccessToken permission. You can also createa custom role.You can specify a list of service accounts, separated with commas. This createsan impersonation delegation chain in which each service account delegates itspermissions to the next service account in the chain. Each service account inthe list must have the
roles/iam.serviceAccountTokenCreatorrole onthe next service account in the list. For example, when the property is setthroughgcloud config set auth/impersonate_service_account=,SERVICE_ACCOUNT_1,the active account must have theSERVICE_ACCOUNT_2roles/iam.serviceAccountTokenCreatorrole on, which must have theSERVICE_ACCOUNT_1roles/iam.serviceAccountTokenCreatorrole on.SERVICE_ACCOUNT_2is the impersonatedservice account andSERVICE_ACCOUNT_1isthe delegate.SERVICE_ACCOUNT_2 login_config_file- Sets the created login configuration file in auth/login_config_file. Calling
gcloud auth loginwill automatically use this login configuration unless it is explicitly unset. service_account_disable_id_token_refresh- If True, disable ID token refresh for service account.
service_account_use_self_signed_jwt- If True, use self signed jwt flow to get service account credentials accesstoken. This only applies to service account json file and not to the legacy .p12file.
token_host- Overrides the token endpoint to provision access tokens. It can be used withPrivate Service Connect.
batchlocation- Default location to use when working with Batch resources. When a
locationvalue is required but not provided, the command will fallback to this value, if set.
billingquota_project- The Google Cloud project that is billed and charged quota for operationsperformed in
gcloud. Whenunset, the default is [CURRENT_PROJECT]. This default bills and charges quotaagainst the current project. If you need to operate on one project, but need tobill your usage against or use quota from a different project, you can use thisflag to specify the billing project. If bothbilling/quota_projectand--billing-projectare specified,--billing-projecttakes precedence.
buildskaniko_cache_ttl- TTL, in hours, of cached layers when using Kaniko. If zero, layer caching isdisabled.
region- Default region to use when working with Cloud Build resources. When a
--regionflag is required but not provided, the command will fallback to this value, if set. timeout- Timeout, in seconds, to wait for builds to complete. If unset, defaults to 10minutes.
use_kaniko- If True, kaniko will be used to build images described by a Dockerfile, insteadof
docker build.
colabregion- Default region to use when working with Colab Enterprise resources. When a
--regionflag is required but not provided, the command will fallback to this value, if set. Please seehttps://cloud.google.com/colab/docs/locationsfor a list of supported regions.
component_manageradditional_repositories- Comma separated list of additional repositories to check for components. Thisproperty is automatically managed by the
gcloud componentsrepositoriescommands. disable_update_check- If True, Google Cloud CLI will not automatically check for updates.
composerlocation- Composer location to use. Each Composer location constitutes an independentresource namespace constrained to deploying environments into Compute Engineregions inside this location. This parameter corresponds to the/locations/<location> segment of the Composer resource URIs beingreferenced.
computeimage_family_scope- Sets how images are selected with image families for disk and instance creation.By default, zonal image resources are used when using an image family in apublic image project, and global image resources are used for all otherprojects. To override the default behavior, set this property to
zonalorglobal. region- Default region to use when working with regional Compute Engine resources. Whena
--regionflag is required but not provided, the command will fallback to this value, if set. To see valid choices, rungcloud compute regionslist. use_new_list_usable_subnets_api- If True, use the new API for listing usable subnets which only returns subnetsin the current project.
zone- Default zone to use when working with zonal Compute Engine resources. When a
--zoneflag is required but not provided, the command will fallback to this value, if set. To see valid choices, rungcloud compute zoneslist.
containerbuild_timeout- Timeout, in seconds, to wait for container builds to complete.
cluster- Name of the cluster to use by default when working with Kubernetes Engine.
use_application_default_credentials- If True, use application default credentials to authenticate to the cluster APIserver.
use_client_certificate- If True, use the cluster's client certificate to authenticate to the cluster APIserver.
container_attachedlocation- Default Google Cloud location to use for Attached clusters.
container_awslocation- Default Google Cloud location to use for Anthos clusters on AWS.
container_azurelocation- Default Google Cloud location to use for Anthos clusters on Azure.
container_bare_metallocation- Default Google Cloud location to use for Anthos clusters on Bare Metal.
container_vmwarelocation- Default Google Cloud location to use for Anthos clusters on VMware.
context_awareuse_client_certificate- If True, use client certificate to authorize user device using Context-awareaccess. This includes user login as well. Some services may not support clientcertificate authorization. If a command sends requests to such services, theclient certificate will not be validated. Run
gcloud topicclient-certificatefor list of services supporting this feature.
dataflowdisable_public_ips- Specifies that Cloud Dataflow workers must not use public IP addresses.
enable_streaming_engine- Set this to true to enable Streaming Engine for the job.
print_only- Prints the container spec to stdout. Does not save in Google Cloud Storage.
datafusionlocation- Datafusion location to use. Each Datafusion location constitutes an independentresource namespace constrained to deploying environments into Compute Engineregions inside this location. This parameter corresponds to the/locations/<location> segment of the Datafusion resource URIs beingreferenced.
datapipelinesdisable_public_ips- Specifies that Cloud Dataflow workers must not use public IP addresses.
enable_streaming_engine- Set this to true to enable Streaming Engine for the job.
dataplexasset- Dataplex asset to use. When an
assetis required but not providedby a flag, the command will fall back to this value, if set. lake- Dataplex lake to use. When a
lakeis required but not provided by aflag, the command will fall back to this value, if set. location- Dataplex location to use. When a
locationis required but notprovided by a flag, the command will fall back to this value, if set. zone- Dataplex zone to use. When a
zoneis required but not provided by aflag, the command will fall back to this value, if set.
dataproclocation- Dataproc location to use. Each Dataproc location constitutes an independentresource namespace constrained to deploying instances into Compute Engine zonesinside the location.
region- Dataproc region to use. Each Dataproc region constitutes an independent resourcenamespace constrained to deploying instances into Compute Engine zones insidethe region.
deploydelivery_pipeline- Delivery Pipeline being managed by Cloud Deploy.
region- Cloud Deploy region to use. Each Cloud Deploy region constitutes an independentresource namespace constrained to deploying instances into Compute Engine zonesinside the region.
deployment_managerglob_imports- Enable import path globbing. Uses glob patterns to match multiple imports in aconfig file.
eventarclocation- The default location to use when working with Eventarc resources. This should beeither
or one of the supportedregions. When aglobal--locationflag is required but not provided, thecommand will fall back to this value, if set.
filestorelocation- Please use the
--locationflag or set the filestore/zone orfilestore/region property. region- Default region to use when working with Cloud Filestore regions. When a
--regionflag is required but not provided, the command will fallback to this value, if set. zone- Default zone to use when working with Cloud Filestore zones. When a
--zoneflag is required but not provided, the command will fallback to this value, if set.
functionsgen2- Default environment to use when working with Cloud Functions resources. Whenneither
--gen2nor--no-gen2is provided, the decisionof whether to use Generation 2 falls back to this value if set. region- Default region to use when working with Cloud Functions resources. When a
--regionflag is required but not provided, the command will fallback to this value, if set. To see valid choices, rungcloud beta functionsregions list.
gcloudignoreenabled- If True, do not upload
.gcloudignorefiles (see$gcloud topicgcloudignore). If False, turn off the gcloudignore mechanism entirelyand upload all files.
gkebackupbackup- Default backup ID to use when working with Backup for GKE Services resources.When a
--backupflag is required but not provided, the command willfall back to this value. backup_plan- Default backup plan ID to use when working with Backup for GKE Servicesresources. When a
--backup-planflag is required but not provided,the command will fall back to this value. location- Default location to use when working with Backup for GKE Services resources.When a
--locationflag is required but not provided, the commandwill fall back to this value. restore- Default restore ID to use when working with Backup for GKE Services resources.When a
--restoreflag is required but not provided, the commandwill fall back to this value. restore_plan- Default restore plan ID to use when working with Backup for GKE Servicesresources. When a
--restore-planflag is required but not provided,the command will fall back to this value.
healthcaredataset- Default dataset to use when working with Cloud Healthcare resources. When a
--datasetflag is required but not provided, the command will fallback to this value, if set. location- Default location to use when working with Cloud Healthcare resources. When a
--locationflag is required but not provided, the command will fallback to this value.
interactivebottom_bindings_line- If True, display the bottom key bindings line.
bottom_status_line- If True, display the bottom status line.
completion_menu_lines- Number of lines in the completion menu.
context- Command context string.
fixed_prompt_position- If True, display the prompt at the same position.
help_lines- Maximum number of help snippet lines.
hidden- If True, expose hidden commands/flags.
justify_bottom_lines- If True, left- and right-justify bottom toolbar lines.
manpage_generator- If True, use the manpage CLI tree generator for unsupported commands.
multi_column_completion_menu- If True, display the completions as a multi-column menu.
prompt- Command prompt string.
show_help- If True, show help as command args are being entered.
suggest- If True, add command line suggestions based on history.
lifescienceslocation- Default location to use when working with Cloud Life Sciences resources. When a
--locationflag is required but not provided, the command will fallback to this value.
lookerregion- Default region to use when working with Cloud Looker resources. When a
regionis required but not provided by a flag, the command willfall back to this value, if set.
lustrelocation- Default location to use when working with Cloud Lustre resources. When a
locationvalue is required but not provided, the command will fallback to this value, if set.
media_assetlocation- Default location to use when working with Cloud Media Asset resources. When a
--locationflag is required but not provided, the command will fallback to this value.
memcacheregion- Default region to use when working with Cloud Memorystore for Memcachedresources. When a
regionis required but not provided by a flag,the command will fall back to this value, if set.
metastorelocation- Default location to use when working with Dataproc Metastore. When a
locationis required but not provided by a flag, the command willfall back to this value, if set. tier- Default tier to use when creating Dataproc Metastore services. When a
tieris required but not provided by a flag, the command will fallback to this value, if set.Valid values are:
developer- The developer tier provides limited scalability and nofault tolerance. Good for low-cost proof-of-concept.enterprise- The enterprise tier provides multi-zone highavailability, and sufficient scalability for enterprise-level Dataproc Metastoreworkloads.
ml_enginelocal_python- Full path to the Python interpreter to use for Cloud ML Engine localpredict/train jobs. If not specified, the default path is the one to the Pythoninterpreter found on system
PATH. polling_interval- Interval (in seconds) at which to poll logs from your Cloud ML Engine jobs. Notethat making it much faster than the default (60) will quickly use all of yourquota.
mpsproduct- Id for Marketplace Solutions Product.
netapplocation- Default location to use when working with Cloud NetApp Files resources. When a
locationvalue is required but not provided, the command will fallback to this value, if set.
notebookslocation- Default location to use when working with Notebook resources. When a
locationvalue is required but not provided, the command will fallback to this value, if set.
privatecalocation- Default location to use when working with Private CA resources. When a
--locationflag is required but not provided, the command will fallback to this value, if set.
proxyaddress- Hostname or IP address of proxy server.
password- Password to use when connecting, if the proxy requires authentication.
port- Port to use when connected to the proxy server.
rdns- If True, DNS queries will not be performed locally, and instead, handed to theproxy to resolve. This is default behavior.
type- Type of proxy being used. Supported proxy types are: [http, http_no_tunnel,socks4, socks5].
username- Username to use when connecting, if the proxy requires authentication.
redisregion- Default region to use when working with Cloud Memorystore for Redis resources.When a
regionis required but not provided by a flag, the commandwill fall back to this value, if set.
runcluster- ID of the cluster or fully qualified identifier for the cluster
cluster_location- Zone or region in which the cluster is located.
platform- Target platform for running commands.
region- Default region to use when working with Cloud Run resources. When a
--regionflag is required but not provided, the command will fallback to this value, if set.
runappsdeployment_service_account- Service account to use when deploying integrations.
sccsecretslocations- A comma separated list of the locations to replicate secrets to. Only applies tosecrets with a user-managed policy.
replication-policy- The type of replication policy to apply to secrets. Allowed values are"automatic" and "user-managed". If user-managed then locations must also beprovided.
spannerinstance- Default instance to use when working with Cloud Spanner resources. When aninstance is required but not provided by a flag, the command will fall back tothis value, if set.
sshputty_force_connect- Whether or not
gcloudshouldautomatically accept new or changed host keys when executing plink/pscp commandson Windows. Defaults to True, but can be set to False to present theseinteractive prompts to the user for host key checking. verify_internal_ip- Whether or not
gcloudshouldperform an initial SSH connection to verify an instance ID is correct whenconnecting via its internal IP. Without this check,gcloudwill simply connect to theinternal IP of the desired instance, which may be wrong if the desired instanceis in a different subnet but happens to share the same internal IP as aninstance in the current subnet. Defaults to True.
storageadditional_headers- Includes arbitrary headers in storage API calls. Accepts a comma separated listof key=value pairs, e.g.
header1=value1,header2=value2. base_retry_delay- Second delay between retrying operations. May be multiplied byexponential_sleep_multiplier.
check_hashes- 'check_hashes' specifies how strictly to require integrity checking fordownloaded data. Legal values are:
- 'if_fast_else_fail' - (default) Only integrity check if the digest will runefficiently (using compiled code), else fail the download.
- 'if_fast_else_skip' - Only integrity check if the server supplies a hash and thelocal digest computation will run quickly, else skip the check.
- 'always' - Always check download integrity regardless of possible performancecosts.
- 'never' - Don't perform download integrity checks. This setting is notrecommended except for special cases such as measuring download performanceexcluding time for integrity checking.
This option exists to assist users who wish to download a composite object andare unable to install crcmod with the C-extension. CRC32c is the only availableintegrity check for composite objects, and without the C-extension, downloadperformance can be significantly degraded by the digest computation. This optionis ignored for daisy-chain copies, which don't compute hashes but instead(inexpensively) compare the cloud source and destination hashes.
check_mv_early_deletion_fee- Block mv commands that may incur an early deletion fee (the source object in amv is deleted).
convert_incompatible_windows_path_characters- Allows automatic conversion of invalid path characters on Windows. If notenabled, Windows will raise an OSError if an invalid character is encountered.
copy_chunk_size- Chunk size used for copying to in clouds or on disk.
download_chunk_size- Chunk size used for downloading to clouds.
exponential_sleep_multiplier- Used in exponential backoff for retrying operations.
key_store_path- Path to a yaml file containing an encryption key, and multiple decryption keysfor use in storage commands. The file must be formatted as follows:
encryption_key:{Acustomer-suppliedorcustomer-managedkey.}decryption_keys:-{Acustomer-suppliedkey}…
Customer-supplied encryption keys must be RFC 4648 section 4 base64-encodedAES256 strings. Customer-managed encryption keys must be of the form
projects/{project}/locations/{location}/keyRings/{key-ring}/cryptoKeys/{crypto-key}. max_retries- Max number of retries for operations like copy.
max_retry_delay- Max second delay between retriable operations.
multipart_chunksize- Specifies partition size in bytes of each part of a multipart upload made by theBoto3 client. To calculate the maximum size of a Boto3 client multipart upload,multiply the multipart_chunk value by the maximum number of parts the APIallows. For AWS S3 this limit is 10000. Values can be provided either in bytesor as human-readable values (e.g., "150M" to represent 150 mebibytes).
multipart_threshold- Files larger than this threshold will be partitioned into parts, uploadedseparately by the Boto3 client, and then combined into a single object.Otherwise, files smaller than this threshold will be uploaded by the Boto3client in a single stream.
parallel_composite_upload_compatibility_check- Determines if the GET bucket call should be performed to check if the defaultstorage class and retention period for the destination bucket meet the criteriafor parallel composite upload.
parallel_composite_upload_component_prefix- The prefix used when naming temporary components created by composite uploads.If the prefix begins with a
/, the temporary components areuploaded relative to the bucket name. If the prefix does not begin with a/, the temporary components are uploaded relative to the prefixportion of the destination object name. For example, consider an upload thatwill create a final object namedgs://bucket/dir1/dir2/object.Using a prefix of/prefixmeans temporary components use names likegs://bucket/prefix/COMPONENT_NAME. Using a prefix ofprefixmeans temporary components use names likegs://bucket/dir1/dir2/prefix/COMPONENT_NAME. Note that this cancomplicate cleaning up temporary components, as they will not all share a commonprefix. If this property is not specified, gcloud storage uses the prefix/gcloud/tmp/parallel_composite_uploads/see_gcloud_storage_cp_help_for_details/.If a chosen prefix results in temporary component names longer than the maximumlength Cloud Storage allows, gcloud storage performs a non-composite upload. parallel_composite_upload_component_size- Specifies the ideal size of a component in bytes, which will act as an upperbound to the size of the components if ceil(file_size /parallel_composite_upload_component_size) is less than the maximum number ofobjects the API allows composing at once. Values can be provided either in bytesor as human-readable values (e.g., "150M" to represent 150 mebibytes).
parallel_composite_upload_enabled- Determines whether parallel composite upload should be used. Default value isNone which will use parallel composite upload and log an appropriate warning forthe user explaining that parallel composite upload is being used by default.
parallel_composite_upload_threshold- Specifies the maximum size of a file to upload in a single stream. Files largerthan this threshold will be partitioned into component parts, uploaded inparallel, then composed into a single object. The number of components will bethe smaller of ceil(file_size / parallel_composite_upload_component_size) andthe maximum number of objects the API allows composing at once. For CloudStorage this limit is 32. This property has no effect ifparallel_composite_upload_enabled is set to False.
process_count- The maximum number of processes parallel execution should use. Whenprocess_count and thread_count are both 1, commands use sequential execution.
resumable_threshold- File operations above this size in bytes will use resumable instead of one-shotstrategies. For example, a resumable download.
rsync_files_directory- Directory path to intermediary files created by rsync.
rsync_list_chunk_size- Number of files processed at a time by the rsync command when it builds andcompares the list of files at the source and destination.
s3_endpoint_url- If set, boto3 client will connect to this endpoint. Otherwise, boto3 selects adefault endpoint based on the AWS service used.
sliced_object_download_component_size- Target size and upper bound for files to be sliced into. Analogous toparallel_composite_upload_component_size.
sliced_object_download_max_components- Specifies the maximum number of slices to be used when performing a slicedobject download. Set None for automatic optimization based on system resources.
sliced_object_download_threshold- Slice files larger than this value. Zero will block sliced downloads. Analogousto parallel_composite_upload_threshold.
suggest_transfer- If True, logs messages about when Storage Transfer Service might be a bettertool than gcloud storage.
thread_count- The number of threads parallel execution should use per process. Whenprocess_count and thread_count are both 1, commands use sequential execution.
tracker_files_directory- Directory path to tracker files for resumable operations.
upload_chunk_size- Chunk size used for uploading to clouds.
use_gcloud_crc32c- If True, data integrity checks use a binary subprocess to calculate CRC32Chashes with the included gcloud-crc32c tool rather than the google-crc32c Pythonlibrary. This behavior is also triggered when the google-crc32c Python libraryis unavailable even if this property is False.
use_gsutil- If True, use the deprecated upload implementation which uses gsutil.
use_gsutil_rsync_delete_unmatched_destination_objects_behavior- If True, rsync will preserve unmatched destination objects while using--delete-unmatched-destination-objects flag along with other flags such as--no-clobber, --skip-unsupported and --skip-if-dest-has-newer-mtime just as itwould with gsutil.
use_magicfile- If True, uses the
file --mime <filename>command to guesscontent types instead of the default filename extension-based mechanism.Available on UNIX and macOS (and possibly on Windows, if you're running Cygwinor some other package that provides implementations of UNIX-like commands). Whenavailable and enabled use_magicfile should be more robust because it analyzesfile contents in addition to extensions. use_threading_local- If True, reuses some resource if they are already declared on a thread. IfFalse, creates duplicates of resources like API clients on the same thread.Turning off can help with some bugs but will hurt performance.
surveydisable_prompts- If True, gcloud will not prompt you to take periodic usage experience surveys.
vmwareregion- Default region to use when working with VMware Engine resources. When a
--regionflag is required but not provided, the command will fallback to this value, if set.
workstationscluster- Default cluster to use when working with Workstations resources. When a
--clusterflag is required but not provided, the command will fallback to this value, if set. config- Default configuration to use when working with Workstations resources. When a
--configflag is required but not provided, the command will fallback to this value, if set. region- Default region to use when working with Workstations resources. When a
--regionflag is required but not provided, the command will fallback to this value, if set.
- NOTES
- These variants are also available:
gcloudalphaconfigsetgcloudbetaconfigsetgcloudpreviewconfigset
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-11-18 UTC.