Redeployment in Kubernetes does not scale down the old Replica set

8/13/2019

When we are trying to redeploy the same deployment which is already running, Deployment does not do the rolling update on the replicasets which means old and new replica sets are running.

I have tried to set the revisionHistoryLimit to 1 but it also does not help. Everytime, I am trying to delete/scale down the old replicaset by

kubectl delete replicaset/<old_replciaset_name> -n <namespace>

or

kubectl scale replicaset/<old_replciaset_name> --replicas=0
-- Karthick Shanmugamoorthy
kubernetes

0 Answers