From 18cadb5759593f2c15e8abea429e21d1480d38c8 Mon Sep 17 00:00:00 2001 From: Chi-En Wu Date: Wed, 22 Apr 2020 12:51:04 +0800 Subject: [PATCH] refactor: correct variable name `$pod` => `$deployment` --- templates/_pdb.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/_pdb.yaml b/templates/_pdb.yaml index 7a65732..c163abf 100644 --- a/templates/_pdb.yaml +++ b/templates/_pdb.yaml @@ -24,9 +24,9 @@ spec: {{- define "common.pdb" -}} {{- $top := first . -}} -{{- $pod := index . 2 -}} +{{- $deployment := index . 2 -}} {{- $autoscaling := index . 3 -}} -{{- if or (and $autoscaling.enabled (gt ($autoscaling.minReplicas | int) 1)) (gt ($pod.replicaCount | int) 1) }} +{{- if or (and $autoscaling.enabled (gt ($autoscaling.minReplicas | int) 1)) (gt ($deployment.replicaCount | int) 1) }} {{- include "common.utils.merge" (append . "common.pdb.tpl") -}} {{- end -}} {{- end -}}