- gcloud alpha auth login - authorize gcloud to access the Cloud Platform with Google user credentials
gcloud alpha auth login [ACCOUNT] [--no-activate] [--brief] [--enable-gdrive-access] [--force] [--no-launch-browser] [GCLOUD_WIDE_FLAG ...]
(ALPHA) Obtains access credentials for your user account via a web-based
If valid credentials for an account are already available from a prior authorization, the account is set to active without rerunning the flow.
Use gcloud auth list to view credentialed accounts.
If you'd rather authorize without a web browser but still interact with the command line, use the --no-launch-browser flag. To authorize without a web browser and non-interactively, create a service account with the appropriate scopes using the Google Cloud Platform Console (console.cloud.google.com and use gcloud auth activate-service-account with the corresponding JSON key file.
For more information on authorization and credential types, see: cloud.google.com/sdk/docs/authorizing
User account used for authorization.
Set the new account to active. Enabled by default, use --no-activate to
Minimal user output.
Enable Google Drive access.
Re-run the web authorization flow even if the given account has valid
Launch a browser for authorization. If not enabled or DISPLAY variable is not
set, prints a URL to standard output to be copied. Enabled by default, use
--no-launch-browser to disable.
GCLOUD WIDE FLAGS
These flags are available to all commands: --account, --configuration, --flags-file, --flatten, --format, --help, --log-http, --project, --quiet, --trace-token, --user-output-enabled, --verbosity. Run $ gcloud help for details.
This command is currently in ALPHA and may change without notice. If this command fails with API permission errors despite specifying the right project, you will have to apply for early access and have your projects registered on the API whitelist to use it. To do so, contact Support at cloud.google.com/support These variants are also available:
- $ gcloud auth login $ gcloud beta auth login