DevNation Day India 2021 - De-mystify Helm Chart Hooks
Abstract
Helm provides a mechanism in the form of hooks to intervene at certain points in a deployment life cycle. In this talk, I will explain hooks in the simplest form along with a Practical use case. I will showcase DB initialization post-install, DB backup pre-upgrade & more such use cases for MySQL DB.
Helm Chart deployment life cycle comprises of following:
- Install
- Upgrade
- Rollback (In case of failure)
- Delete
So If you want to perform a certain task at a particular stage before or after then hooks become the obvious choice. Helm provides a total of 9 Hooks, Two (Pre & Post) for each stage for e.g. pre-install & post-install, and one for the test.
To explain the hooks I will use MySQL DB in the form of a container. I will showcase the following scenarios with MySQL DB deployment lifecycle:
- DB initialization post-install.
- DB backup pre-upgrade.
- DB restore post-rollback.
- Clean up post-delete
All the above scenarios are practical and widely performed by DB Admins. With Helm Hooks, I am trying to automate all these tasks through Kubernetes Job.
The talk will include both a presentation and a demo on the above scenarios.
Sagar Jadhav, Software Engineer, IBM
Sagar Jadhav has over 8+ years of experience in Software Development. He has experience in a wide range of tools & technologies such as Java, Cloud, Kubernetes, Golang, Terraform, etc. He is currently working as a Software Engineer at IBM. He is working in Hybrid Cloud Space and currently working on a product used for Infrastructure automation and management. He is always keen to learn new technologies specifically related to DevOps & Cloud-Native and also believes in sharing the same with others through meetups, conferences, webinars & blogs. Find him on LinkedIn.