A developer needs a quick, valid way to change one container image on a Deployment and start a rolling update without hand-editing the full manifest. Which approach is appropriate?
Select an answer to reveal the explanation.
Short Explanation
Need a new container image without rewriting the whole YAML novel? kubectl set image patches the Deployment container image and kicks off the rolling replacement for you.
Full Explanation
kubectl set image updates the named container’s image on a Deployment (or other supported controllers), which changes the Pod template and triggers a rolling update. Labeling Pods, tainting nodes, or using kubectl attach are unrelated to declaring a new Deployment image and do not correctly start that rollout path.