Automated alternative for initiating a rolling update for a deployment

Viewed 898

So in order to update the images running on a pod, I have to modify the deployment config (yaml file), and run something like kubectl apply -f deploy.yaml.

This means, if I'm not editing the yaml file manually I'll have to use some template / search and replace functionality. Which isn't really ideal.

Are there any better approaches?

It seems there is a kubectl rolling-update command, but I'm not sure if this works for 'deployments'.

For example running the following: kubectl rolling-update wordpress --image=eu.gcr.io/abcxyz/wordpress:deploy-1502443760

Produces an error of:

error: couldn't find a replication controller with source id == default/wordpress
1 Answers
Related