1
0
Fork 0
mirror of https://github.com/imjasonh/gcloud-help synced 2026-07-11 15:39:42 +00:00
gcloud-help/gcloud/edge-cloud/container/clusters/get-credentials

83 lines
3.2 KiB
Text
Raw Normal View History

2022-04-06 08:36:53 +00:00
NAME
gcloud edge-cloud container clusters get-credentials - get credentials of
an edge-container cluster
SYNOPSIS
gcloud edge-cloud container clusters get-credentials
(CLUSTER : --location=LOCATION)
[--auth-provider-cmd-path=AUTH_PROVIDER_CMD_PATH]
2024-01-31 10:36:17 +00:00
[--offline-credential] [GCLOUD_WIDE_FLAG ...]
2022-04-06 08:36:53 +00:00
DESCRIPTION
Fetch credentials for a running Edge Container cluster. This command
updates a kubeconfig file with appropriate credentials and endpoint
information to point kubectl at a specific Edge Container cluster. By
default, credentials are written to HOME/.kube/config. You can provide an
alternate path by setting the KUBECONFIG environment variable. If
KUBECONFIG contains multiple paths, the first one is used. This command
enables switching to a specific cluster, when working with multiple
clusters. It can also be used to access a previously created cluster from a
new workstation. The command will configure kubectl to automatically
refresh its credentials using the same identity as the gcloud command-line
tool. See https://cloud.google.com/kubernetes-engine/docs/kubectl for
kubectl documentation.
EXAMPLES
To get credentials of a cluster named my-cluster managed in location
us-west1, run: $ gcloud edge-cloud container clusters get-credentials my-cluster \
--location=us-west1
POSITIONAL ARGUMENTS
2023-03-29 10:40:15 +00:00
Cluster resource - Edge Container cluster to get credentials. The
2022-04-06 08:36:53 +00:00
arguments in this group can be used to specify the attributes of this
resource. (NOTE) Some attributes are not given arguments in this group but
2023-05-04 10:43:54 +00:00
can be set in other ways.
To set the project attribute:
2022-04-06 08:36:53 +00:00
◆ provide the argument cluster on the command line with a fully
specified name;
◆ provide the argument --project on the command line;
◆ set the property core/project.
This must be specified.
CLUSTER
2023-05-04 10:43:54 +00:00
ID of the cluster or fully qualified identifier for the cluster.
To set the cluster attribute:
2022-04-06 08:36:53 +00:00
▸ provide the argument cluster on the command line.
2022-08-10 08:48:58 +00:00
This positional argument must be specified if any of the other
arguments in this group are specified.
2022-04-06 08:36:53 +00:00
--location=LOCATION
2023-05-04 10:43:54 +00:00
Google Cloud location for the cluster.
To set the location attribute:
2022-04-06 08:36:53 +00:00
▸ provide the argument cluster on the command line with a fully
specified name;
▸ provide the argument --location on the command line.
FLAGS
--auth-provider-cmd-path=AUTH_PROVIDER_CMD_PATH
Path to the gcloud executable for the auth provider field in
kubeconfig.
2024-01-31 10:36:17 +00:00
--offline-credential
Once specified, an offline credential will be generated for the
cluster.
2022-04-06 08:36:53 +00:00
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 variant is also available:
$ gcloud alpha edge-cloud container clusters get-credentials