Soru

Zorluk: KolayDeploying and Managing Google Kubernetes Engine (GKE) Clusters and Workloads

A cloud administrator needs to establish command-line management from a local workstation to a newly created Google Kubernetes Engine (GKE) cluster and deploy an application. Which two actions must the administrator perform to authenticate kubectl and deploy the Kubernetes workload? (Select TWO.)

  1. Run `gcloud container clusters get-credentials` specifying the cluster name and location to update the local kubeconfig context.Cevap
  2. Execute `kubectl apply -f` referencing the application deployment manifest files.Cevap
  3. C
    Execute `gcloud config set container/cluster` to authenticate `kubectl` directly without modifying kubeconfig files.
  4. D
    Provision a dedicated Spot VM node pool to host a non-fault-tolerant primary database workload requiring constant availability.

Cevap

The administrator must update local kubeconfig credentials using `gcloud container clusters get-credentials` and deploy the application resources using `kubectl apply -f`.
To administer a GKE cluster via `kubectl`, an administrator must first fetch the cluster credentials using `gcloud container clusters get-credentials`, which updates the local `kubeconfig` context. Once authentication is established, executing `kubectl apply -f` deploys the defined Kubernetes manifests to the cluster.

Adım Adım Çözüm

1
Authenticate kubectl to the GKE cluster
Local kubeconfig file is updated with cluster API server endpoints and access credentials.
kubectl requires context information from kubeconfig to communicate with the GKE control plane.
2
Apply the workload configuration manifests
Kubernetes Deployment and related resources are created in the cluster.
kubectl apply reads the declarative YAML manifests and submits them to the GKE API server for deployment.

Anahtar Kavram

Authenticating to GKE clusters with gcloud get-credentials and managing workloads with kubectl
Bu soruyu puanla