mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-31 03:45:17 +00:00
fix: pod stay in terminating when scaling to 0 (#3793)
Signed-off-by: Charles-Edouard Brétéché <charled.breteche@gmail.com> Co-authored-by: Vyankatesh Kudtarkar <vyankateshkd@gmail.com>
This commit is contained in:
parent
af51ceb4ff
commit
db735f2165
1 changed files with 1 additions and 1 deletions
|
@ -260,7 +260,7 @@ func (wrc *Register) cleanupKyvernoResource() bool {
|
|||
logger.Info("Kyverno is terminating, cleanup Kyverno resources")
|
||||
return true
|
||||
}
|
||||
if deploy.Spec.Replicas == nil && *deploy.Spec.Replicas == 0 {
|
||||
if deploy.Spec.Replicas != nil && *deploy.Spec.Replicas == 0 {
|
||||
logger.Info("Kyverno is scaled to zero, cleanup Kyverno resources")
|
||||
return true
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue