- NAME
- gcloud auth activate-service-account - get credentials via the private key for a service account
- SYNOPSIS
-
gcloud auth activate-service-account
ACCOUNT
[--format
FORMAT
] [--help
] --key-file
KEY_FILE
[--password-file
PASSWORD_FILE
| --prompt-for-password
] [--project
PROJECT_ID
] [--quiet
, -q
] [--trace-token
TRACE_TOKEN
] [-h
]
- DESCRIPTION
- Get credentials for a service account, using a .json file or a .p12 file
for the private key.
Password is only applicable for .p12 file.
If --project is set, set the default project.
- POSITIONAL ARGUMENTS
-
ACCOUNT
-
The email for the service account.
- FLAGS
-
--key-file
KEY_FILE
-
Path to the service accounts private key.
-
--password-file
PASSWORD_FILE
-
Path to a file containing the password for the service account private key (only for .p12 file).
-
--prompt-for-password
-
Prompt for the password for the service account private key (only for .p12 file).
- GLOBAL FLAGS
-
--format
FORMAT
-
Specify a format for printed output. By default, a command-specific
human-friendly output format is used. Setting this flag to one of
the available options will serialize the result of the command in
the chosen format and print it to stdout. Supported formats are:
json
, text
, yaml
.
-
--help
-
Display detailed help.
-
--project
PROJECT_ID
-
The Google Cloud Platform project name to use for this invocation. If
omitted then the current project is assumed.
-
--quiet
, -q
-
Disable all interactive prompts when running gcloud commands. If input
is required, defaults will be used, or an error will be raised.
-
--trace-token
TRACE_TOKEN
-
Token used to route traces of service requests for investigation of issues.
-
-h
-
Print a summary help and exit.
- NOTES
- This command is in the Google Cloud SDK
core
component. See
installing components
if it is not installed.