How to update multiple deployments simultaneously and deploy only if all succeed?

5/17/2017

I'm not sure if I saw this type of functionality before, but I believe I did last fall. However I can't seem to find any documentation for it now so I thought I'd ask here.

I have a bunch of microservices set up with kubernetes. Currently when a new version of a microservice is ready for release, I do a kubectl set image which updates the image for a deployment. If the rollout gets stuck, the old image is never taken down. Hence our microservice stays up.

However, I was wondering how to update multiple microservices simultaneously with the same sort of functionality as above.

Specifically, let's say I have a frontend service that depends on a backend service. Let's say the front end makes a POST with a specific signature to the backend in version 1. If in version 2, that signature changes, I need both my frontend and backend services to update at the same time. If either deployment gets stuck, I wouldn't want either to have deployed because that would cause both microservices to not work.

So my question is, how do you simultaneously update multiple deployments in kubernetes while ensuring that none of the old images are taken down until all of the new ones are successfully up?

-- Terence Chow
kubernetes

1 Answer

5/18/2017

You should take a look at the official Kubernetes package manager called Helm.

Helm supports packaging multiple deployments and services into a single release. This allows you to perform upgrades and rollbacks over all resources in the release.

-- Lukas Eichler
Source: StackOverflow