A developer has a directory with kustomization.yaml and wants Kubernetes to build and apply that overlay in one step. Which kubectl invocation is appropriate?
Select an answer to reveal the explanation.
Short Explanation
kubectl apply -k is the built-in “assemble then submit” button. Point it at the overlay folder and it renders the Kustomize build before applying—no separate kustomize binary required for the common case.
Full Explanation
kubectl apply -k invokes kubectl’s Kustomize integration to build the directory tree and apply the result. Other kubectl verbs such as run, attach, or cordon are unrelated to applying a kustomization and will not deploy the overlay correctly.