200-901 Application Deployment and Security Practice Question
A developer needs to apply a Kubernetes deployment manifest from a file named 'deployment.yaml'. Which kubectl command should be used?
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
kubectl apply -f deployment.yaml
kubectl apply -f creates or updates resources from a file. get, describe, and create are not used for applying manifests.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
kubectl apply -f deployment.yaml
Why this is correct
`kubectl apply -f deployment.yaml` reads the manifest from the named file and applies its declared state to the cluster, satisfying the requirement to deploy from a file. The `-f` flag specifies the file path, while `apply` performs a declarative create-or-update, unlike imperative `create` or `run`.
- ✗
kubectl create deployment.yaml
Why it's wrong here
create expects resource type and name arguments, not a bare filename, so it cannot parse deployment.yaml as a manifest. It suits imperative creation of simple resources. Applying a declarative manifest file requires a command that reads the YAML and submits its objects.
- ✗
kubectl describe -f deployment.yaml
Why it's wrong here
describe reads and prints details of existing resources; it does not submit manifests to the API server. It suits inspecting a deployed resource's state and events. Applying a manifest requires a command that sends the file's objects to the cluster for creation or update.
- ✗
kubectl get -f deployment.yaml
Why it's wrong here
kubectl get retrieves and lists existing resources; it does not create or apply anything from the manifest. The verb is tempting because -f accepts a filename, but apply is the command that submits the manifest to the API server, which is what the developer needs.
Go deeper
Related to this question
About these practice questions
This 200-901 question is part of Courseiva's 975-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This 200-901 practice question is part of Courseiva's free Cisco certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the 200-901 exam.