ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 5 - Associate Cloud Engineer discussion

Report
Export

You are using multiple configurations for gcloud. You want to review the configured Kubernetes Engine cluster of an inactive configuration using the fewest possible steps. What should you do?

A.
Use gcloud config configurations describe to review the output.
Answers
A.
Use gcloud config configurations describe to review the output.
B.
Use gcloud config configurations activate and gcloud config list to review the output.
Answers
B.
Use gcloud config configurations activate and gcloud config list to review the output.
C.
Use kubectl config get-contexts to review the output.
Answers
C.
Use kubectl config get-contexts to review the output.
D.
Use kubectl config use-context and kubectl config view to review the output.
Answers
D.
Use kubectl config use-context and kubectl config view to review the output.
Suggested answer: D

Explanation:

kubectl config view -o jsonpath='{.users[].name}' # display the first user

kubectl config view -o jsonpath='{.users[*].name}' # get a list of users

kubectl config get-contexts # display list of contexts

kubectl config current-context # display the current-context

kubectl config use-context my-cluster-name # set the default context to my-cluster-name

https://kubernetes.io/docs/reference/kubectl/cheatsheet/

asked 18/09/2024
Nathalie Yip
38 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first