Canary deployments: Go easy with Ketch 0.2!

What is a Canary Deployment? ๐Ÿค”

The term canary refers to the practice of bringing canaries into coal mines to determine if the mine is safe for humans. Miners used to carry caged canaries (birds) down into the mine tunnels with them. If dangerous gases such as carbon monoxide collected in the mine, the gases would kill the canary before killing the miners, thus providing a warning to exit the tunnels immediately.

Why makes Ketch special for Canary deployments?

In general, Canarying involves manual work, such as:

  • Evaluating the new version regularly and check if it is not in a broken/failed state.
  • Increase the user traffic to the new version manually with time.
  • Rollback if the new version fails at some point in time.
  • Of course, writing the boring K8s YAML. ๐Ÿ˜ฉ

Letโ€™s automate Canary rollouts with Ketch! โ›ต๏ธ

I am assuming that you have already installed the Ketch controller into your cluster. If not, you could get it done in a few minutes by reading the steps described here.

$ sudo route -n add -host -net $(kubectl get svc traefik -o jsonpath='{.spec.clusterIP}') $(minikube ip -p ketch)
$ ketch app deploy a1 -i docker.io/dockercloud/hello-world --steps 10  --step-interval 1h

Automatic Rollback

Ketch will keep eye on the deployment and will keep checking the health of the pods for the deployment. If the canary pods get into an unhealthy state during the rollout, Ketch will rollback all the traffic to primary deployment if it exceeds a certain timeout period in an unhealthy state.

  • Ketch now supports Istio 1.8.x and above and fully working with secure TLS support.

Conclusion

Ketch is a great framework and it makes it extremely easy to deploy and manage applications on Kubernetes using a simple command-line interface. No Kubernetes object YAML is required!

Resources:

Learn more about Ketch at https://www.theketch.io/ โœจ

About the Author:

I am Saurabh, a passionate and creative developer from ๐Ÿ‡ฎ๐Ÿ‡ณ with a strong interest in Open-Source. ๐ŸŽฏ I have contributed to some of the big projects by giant firms like @๐—š๐—ผ๐—ผ๐—ด๐—น๐—ฒ, @๐—š๐—ถ๐˜๐—ต๐˜‚๐—ฏ, @๐——๐—ถ๐—ด๐—ถ๐˜๐—ฎ๐—น๐—ข๐—ฐ๐—ฒ๐—ฎ๐—ป, @๐—ข๐—ฝ๐—ฒ๐—ป๐—™๐—ฎ๐—ฎ๐˜€,@๐—ต๐—ฒ๐—น๐—น๐—ผ๐—ณ๐—ฟ๐—ฒ๐˜€๐—ต, and many more.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store