gcloud alpha auth configure-docker

NAME
gcloud alpha auth configure-docker - registergcloud as a Docker credential helper
SYNOPSIS
gcloud alpha auth configure-docker[REGISTRIES][GCLOUD_WIDE_FLAG]
DESCRIPTION
(ALPHA) gcloud alpha auth configure-docker adds the DockercredHelper entry to Docker's configuration file, or creates thefile if it doesn't exist. This will registergcloud as the credential helper for allGoogle-supported Docker registries. If the Docker configuration already containsacredHelper entry, it will be overwritten.

Note:docker andgcloud need to be on the same systemPATH to work correctly.

Note: This command will not work fordocker installed via Snap, asthedocker snap package does not currently provide an interface forcredential helpers.

For more details on Docker registries, seehttps://docs.docker.com/registry/.

For more details on how to authenticate to Google Container Registry using thiscommand, seehttps://cloud.google.com/container-registry/docs/advanced-authentication#gcloud-helper.

For more details on Google Container Registry's standalone credential helpers,seehttps://github.com/GoogleCloudPlatform/docker-credential-gcr.

For more details on Docker credential helpers, seehttps://docs.docker.com/engine/reference/commandline/login/#credential-helpers.

EXAMPLES
To configure docker authentication after logging into gcloud, run:
gcloudalphaauthconfigure-docker

To configure docker authentication with Container Registry, e.g.,gcr.io, run:

gcloudalphaauthconfigure-dockergcr.io
POSITIONAL ARGUMENTS
[REGISTRIES]
The comma-separated list of registries to configure the credential helper for.Container Registry is a service for storing private container images. Foravailable registries, seehttps://cloud.google.com/container-registry/docs/pushing-and-pulling#add-registry.
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 help for details.

NOTES
This command is currently in alpha and might change without notice. If thiscommand fails with API permission errors despite specifying the correct project,you might be trying to access an API with an invitation-only early accessallowlist. These variants are also available:
gcloudauthconfigure-docker
gcloudbetaauthconfigure-docker

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-05-07 UTC.