Jump to content

Kubernetes: Difference between revisions

Line 497: Line 497:
===Scale to 0===
===Scale to 0===
[https://stackoverflow.com/questions/64133011/scale-down-kubernetes-deployments-to-0-and-scale-back-to-original-number-of-repl reference]<br>
[https://stackoverflow.com/questions/64133011/scale-down-kubernetes-deployments-to-0-and-scale-back-to-original-number-of-repl reference]<br>
If you wish to restart your cluster, you can scale your deployments and stateful sets down to 0 and then scale them back up after.
If you wish to restart all nodes of your cluster, you can scale your deployments and stateful sets down to 0 and then scale them back up after.
<syntaxhighlight lang="bash">
<syntaxhighlight lang="bash">
# Annotate existing deployments and statefulsets with replica count.
# Annotate existing deployments and statefulsets with replica count.