Kubernetes deployment strategies visualized
Blog post from Octopus Deploy
Kubernetes offers two native deployment strategies, recreate and rolling update, which allow administrators and developers to manage software or configuration deployments with varying approaches to downtime and concurrency. The recreate strategy deletes old pods before creating new ones, ensuring no concurrency but causing downtime, which is useful for backend datastores that cannot handle simultaneous client versions. The rolling update strategy, on the other hand, incrementally replaces old pods with new ones, maintaining some active pods to prevent downtime but requiring datastores to support concurrent client versions. Additionally, Octopus provides a blue/green deployment strategy, not natively supported by Kubernetes, which involves creating a new deployment, switching traffic to it once ready, and then deleting the old deployment. This method ensures the new deployment is fully operational before traffic is switched, offering a safety net by allowing for rollback if the new deployment fails, but also requiring datastores to handle concurrent versions temporarily. Understanding these strategies is crucial for selecting the appropriate method based on specific deployment needs and minimizing potential downtime.