Home » Microsoft » AZ-300 » Which command should you run next?
You have an Azure Kubernetes Service (AKS) cluster named Clus1 in a resource group named RG1.
An administrator plans to manage Clus1 from an Azure AD-joined device.
You need to ensure that the administrator can deploy the YAML application manifest file for a container application.
You install the Azure CLI on the device.
Which command should you run next?
A. kubectl get nodes
B. az aks install-cli
C. kubectl apply -f appl.yaml
D. az aks get-credentials –resource-group RG1 –name Clus1
Correct Answer: C
Explanation/Reference:
Explanation:
kubectl apply -f appl.yaml applies a configuration change to a resource from a file or stdin.
Incorrect Answers:
A: kubectl get nodes gets a list of all nodes.
B: az aks install-cli download and install the Kubernetes command-line tool.
D: az aks get-credentials gets access credentials for a managed Kubernetes cluster
References:
https://kubernetes.io/docs/reference/kubectl/overview/
https://docs.microsoft.com/en-us/cli/azure/aks
Correct Answer: B
“To manage a Kubernetes cluster, you use kubectl, the Kubernetes command-line client… To install kubectl locally, use the az aks install-cli command”
https://docs.microsoft.com/en-us/azure/aks/kubernetes-walkthrough