Skip to content

Commit

Permalink
feat(helm): unify and extend hook job pod labels (#2205)
Browse files Browse the repository at this point in the history
Signed-off-by: Viktor Oreshkin <imselfish@stek29.rocks>
  • Loading branch information
stek29 committed Aug 3, 2022
1 parent 557394f commit 60912f6
Show file tree
Hide file tree
Showing 10 changed files with 46 additions and 0 deletions.
Expand Up @@ -19,7 +19,11 @@ spec:
annotations:
{{- toYaml .Values.podAnnotations | trim | nindent 8 }}
labels:
{{- include "gatekeeper.podLabels" . }}
app: '{{ template "gatekeeper.name" . }}'
chart: '{{ template "gatekeeper.name" . }}'
gatekeeper.sh/system: "yes"
heritage: '{{ .Release.Service }}'
release: '{{ .Release.Name }}'
spec:
restartPolicy: OnFailure
Expand Down
Expand Up @@ -17,7 +17,11 @@ spec:
template:
metadata:
labels:
{{- include "gatekeeper.podLabels" . }}
app: '{{ template "gatekeeper.name" . }}'
chart: '{{ template "gatekeeper.name" . }}'
gatekeeper.sh/system: "yes"
heritage: '{{ .Release.Service }}'
release: '{{ .Release.Name }}'
spec:
restartPolicy: OnFailure
Expand Down
Expand Up @@ -20,7 +20,11 @@ spec:
annotations:
{{- toYaml .Values.podAnnotations | trim | nindent 8 }}
labels:
{{- include "gatekeeper.podLabels" . }}
app: '{{ template "gatekeeper.name" . }}'
chart: '{{ template "gatekeeper.name" . }}'
gatekeeper.sh/system: "yes"
heritage: '{{ .Release.Service }}'
release: '{{ .Release.Name }}'
spec:
restartPolicy: Never
Expand Down
7 changes: 7 additions & 0 deletions cmd/build/helmify/static/templates/upgrade-crds-hook.yaml
Expand Up @@ -77,6 +77,13 @@ spec:
name: gatekeeper-update-crds-hook
annotations:
{{- toYaml .Values.podAnnotations | trim | nindent 8 }}
labels:
{{- include "gatekeeper.podLabels" . }}
app: '{{ template "gatekeeper.name" . }}'
chart: '{{ template "gatekeeper.name" . }}'
gatekeeper.sh/system: "yes"
heritage: '{{ .Release.Service }}'
release: '{{ .Release.Name }}'
spec:
serviceAccountName: gatekeeper-admin-upgrade-crds
restartPolicy: Never
Expand Down
Expand Up @@ -19,7 +19,11 @@ spec:
annotations:
{{- toYaml .Values.podAnnotations | trim | nindent 8 }}
labels:
{{- include "gatekeeper.podLabels" . }}
app: '{{ template "gatekeeper.name" . }}'
chart: '{{ template "gatekeeper.name" . }}'
gatekeeper.sh/system: "yes"
heritage: '{{ .Release.Service }}'
release: '{{ .Release.Name }}'
spec:
restartPolicy: OnFailure
Expand Down
Expand Up @@ -19,7 +19,11 @@ spec:
annotations:
{{- toYaml .Values.podAnnotations | trim | nindent 8 }}
labels:
{{- include "gatekeeper.podLabels" . }}
app: '{{ template "gatekeeper.name" . }}'
chart: '{{ template "gatekeeper.name" . }}'
gatekeeper.sh/system: "yes"
heritage: '{{ .Release.Service }}'
release: '{{ .Release.Name }}'
spec:
restartPolicy: OnFailure
Expand Down
Expand Up @@ -17,7 +17,11 @@ spec:
template:
metadata:
labels:
{{- include "gatekeeper.podLabels" . }}
app: '{{ template "gatekeeper.name" . }}'
chart: '{{ template "gatekeeper.name" . }}'
gatekeeper.sh/system: "yes"
heritage: '{{ .Release.Service }}'
release: '{{ .Release.Name }}'
spec:
restartPolicy: OnFailure
Expand Down
Expand Up @@ -20,7 +20,11 @@ spec:
annotations:
{{- toYaml .Values.podAnnotations | trim | nindent 8 }}
labels:
{{- include "gatekeeper.podLabels" . }}
app: '{{ template "gatekeeper.name" . }}'
chart: '{{ template "gatekeeper.name" . }}'
gatekeeper.sh/system: "yes"
heritage: '{{ .Release.Service }}'
release: '{{ .Release.Name }}'
spec:
restartPolicy: Never
Expand Down
Expand Up @@ -77,6 +77,13 @@ spec:
name: gatekeeper-update-crds-hook
annotations:
{{- toYaml .Values.podAnnotations | trim | nindent 8 }}
labels:
{{- include "gatekeeper.podLabels" . }}
app: '{{ template "gatekeeper.name" . }}'
chart: '{{ template "gatekeeper.name" . }}'
gatekeeper.sh/system: "yes"
heritage: '{{ .Release.Service }}'
release: '{{ .Release.Name }}'
spec:
serviceAccountName: gatekeeper-admin-upgrade-crds
restartPolicy: Never
Expand Down
Expand Up @@ -19,7 +19,11 @@ spec:
annotations:
{{- toYaml .Values.podAnnotations | trim | nindent 8 }}
labels:
{{- include "gatekeeper.podLabels" . }}
app: '{{ template "gatekeeper.name" . }}'
chart: '{{ template "gatekeeper.name" . }}'
gatekeeper.sh/system: "yes"
heritage: '{{ .Release.Service }}'
release: '{{ .Release.Name }}'
spec:
restartPolicy: OnFailure
Expand Down

0 comments on commit 60912f6

Please sign in to comment.