kubernetes - Strategies for using rolling updates on multi-container replication controllers? -
is there way rolling-update replication controller has 2 or more containers?
for example, have jenkins setup automatically rolling update on rep controller in our dev environment once successful build takes place using --image flag specifying new container's image stored in gcr. method doesn't work when there 2 containers in same pod , there no "-c" flag specify container wish update on rolling-update command there on other commands such "exec" or "logs".
the reason i'm looking have multiple pods implement logging sidecar in: https://github.com/kubernetes/contrib/tree/master/logging/fluentd-sidecar-es
the alternative can think of bake fluentd config each container, feels decidedly 'un-kubernetes' me.
you right in saying kubectl rolling-update frontend --image=image:v2
not give way provide more details container when updating pod has more 1 container. gives error image update not supported multi-container pods
but, gives 2 variants
kubectl rolling-update frontend-v1 -f frontend-v2.json
cat frontend-v2.json | kubectl rolling-update frontend-v1 -f -
where v1 , v2 can build versions. way, have advantage of pod names adhering build versions too.
Comments
Post a Comment