Skip to content

Commit

Permalink
chore: Changed the process to expand yaml so that maxUnavailable, etc…
Browse files Browse the repository at this point in the history
…. can be used.

Signed-off-by: kahirokunn <[email protected]>
  • Loading branch information
kahirokunn committed Feb 12, 2024
1 parent 0bac5b0 commit a51aff0
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ metadata:
release: '{{ .Release.Name }}'
name: gatekeeper-controller-manager
namespace: '{{ .Release.Namespace }}'
spec:
minAvailable: {{ .Values.pdb.controllerManager.minAvailable }}
spec: {{ .Values.pdb.controllerManager | toYaml | nindent 2 }}
selector:
matchLabels:
app: '{{ template "gatekeeper.name" . }}'
Expand Down
2 changes: 1 addition & 1 deletion cmd/build/helmify/kustomize-for-helm.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ metadata:
name: gatekeeper-controller-manager
namespace: gatekeeper-system
spec:
minAvailable: HELMSUBST_PDB_CONTROLLER_MANAGER_MINAVAILABLE
minAvailable: HELMSUBST_PDB_CONTROLLER_MANAGER
selector:
matchLabels:
control-plane: controller-manager
Expand Down
2 changes: 1 addition & 1 deletion cmd/build/helmify/replacements.go
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ var replacements = map[string]string{
- 'services/status'
{{- end }}`,

"HELMSUBST_PDB_CONTROLLER_MANAGER_MINAVAILABLE": `{{ .Values.pdb.controllerManager.minAvailable }}`,
"HELMSUBST_PDB_CONTROLLER_MANAGER": `{{ .Values.pdb.controllerManager | toYaml | nindent 2 }}`,

`HELMSUBST_AUDIT_CONTROLLER_MANAGER_DEPLOYMENT_IMAGE_RELEASE: ""`: `{{- if .Values.image.release }}
image: {{ .Values.image.repository }}:{{ .Values.image.release }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ metadata:
name: gatekeeper-controller-manager
namespace: '{{ .Release.Namespace }}'
spec:
minAvailable: {{ .Values.pdb.controllerManager.minAvailable }}
minAvailable: {{ .Values.pdb.controllerManager | toYaml | nindent 2 }}
selector:
matchLabels:
app: '{{ template "gatekeeper.name" . }}'
Expand Down

0 comments on commit a51aff0

Please sign in to comment.