CKAD Application Deployment Practice Question
You are using Kustomize. Your kustomization.yaml file specifies a base and an overlay. You run: kubectl apply -k overlays/production. What happens?
⚠ Common exam trap
The trap here is that candidates might think `-k` applies only the contents of the specified directory (like `-f` does), but Kustomize always resolves the full overlay chain, including the base, so the result is a merged output, not just the overlay's files.
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
✓
It applies the merged result of base and overlay.
When you run `kubectl apply -k overlays/production`, Kustomize reads the `kustomization.yaml` in the specified directory, which references a base and an overlay. It then performs a strategic merge patch of the overlay's customizations (e.g., patches, namePrefix, commonLabels) onto the base resources, producing a single set of manifests that are applied to the cluster. This is the core purpose of Kustomize: to compose and customize resources without templating.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
It errors because -k expects a directory with kustomization.yaml.
Why it's wrong here
The -k flag in kubectl does require a directory containing a kustomization.yaml file, but in this case the specified overlays/production directory does contain one (the overlay's kustomization.yaml), so no error occurs. The command will not fail for that reason; it will proceed to process the kustomization and render the final manifests.
- ✗
It applies the base resources only.
Why it's wrong here
Kustomize does not apply only the base resources because it reads the kustomization.yaml in the overlay directory, which references the base as a resource. The overlay may add patches, set namespaces, or alter images, and the output is the combined result of both base and overlay definitions. Since the command targets the overlay, the base resources are transformed and included as part of the merged output.
- ✓
It applies the merged result of base and overlay.
Why this is correct
When you run kubectl apply -k overlays/production, kustomize reads the kustomization.yaml in that overlay directory, which typically lists the base directory as a resource. It then merges the base resources with overlay-specific patches, strategic merge patches, name prefixes, labels, or namespace changes, producing a single unified manifest set. This rendered output is sent to kubectl apply, which creates or updates the live cluster objects accordingly.
- ✗
It applies the overlay resources only.
Why it's wrong here
The overlay by itself usually does not contain complete resource definitions; it is composed of patches and configuration such as namespace, labels, or image overrides that are applied on top of the base. If the overlay files were applied on their own, they would miss the underlying resources defined in the base. The correct behavior is that kustomize renders the union of base and overlay patches, so the final applied resources include the base resources with the overlay modifications.
Go deeper
Related to this question
About these practice questions
Courseiva writes every CKAD question from scratch — 826 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or 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 CKAD practice question is part of Courseiva's free CNCF 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 CKAD exam.