feat(helm): add pod and deployment annotations to template (#14030)

This commit is contained in:
Bruno FERNANDO 2021-04-09 17:09:59 +02:00 committed by GitHub
parent 2c96c5b341
commit 9e03b6d122
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 39 additions and 0 deletions

View File

@ -24,6 +24,10 @@ metadata:
chart: {{ template "superset.chart" . }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- if .Values.supersetCeleryBeat.deploymentAnnotations }}
annotations:
{{ toYaml .Values.supersetCeleryBeat.deploymentAnnotations | nindent 4 }}
{{- end }}
spec:
# This must be a singleton
replicas: 1
@ -44,6 +48,9 @@ spec:
# Optionally force the thing to reload
force-reload: {{ randAlphaNum 5 | quote }}
{{ end }}
{{- if .Values.supersetCeleryBeat.podAnnotations }}
{{ toYaml .Values.supersetCeleryBeat.podAnnotations | nindent 8 }}
{{- end }}
labels:
app: {{ template "superset.name" . }}-celerybeat
release: {{ .Release.Name }}

View File

@ -23,6 +23,10 @@ metadata:
chart: {{ template "superset.chart" . }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- if .Values.supersetWorker.deploymentAnnotations }}
annotations:
{{ toYaml .Values.supersetWorker.deploymentAnnotations | nindent 4 }}
{{- end }}
spec:
replicas: {{ .Values.replicaCount }}
selector:
@ -42,6 +46,9 @@ spec:
# Optionally force the thing to reload
force-reload: {{ randAlphaNum 5 | quote }}
{{ end }}
{{- if .Values.supersetWorker.podAnnotations }}
{{ toYaml .Values.supersetWorker.podAnnotations | nindent 8 }}
{{- end }}
labels:
app: {{ template "superset.name" . }}-worker
release: {{ .Release.Name }}

View File

@ -23,6 +23,10 @@ metadata:
chart: {{ template "superset.chart" . }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- if .Values.supersetNode.deploymentAnnotations }}
annotations:
{{ toYaml .Values.supersetNode.deploymentAnnotations | nindent 4 }}
{{- end }}
spec:
replicas: {{ .Values.replicaCount }}
selector:
@ -45,6 +49,9 @@ spec:
# Optionally force the thing to reload
force-reload: {{ randAlphaNum 5 | quote }}
{{- end }}
{{- if .Values.supersetNode.podAnnotations }}
{{ toYaml .Values.supersetNode.podAnnotations | nindent 8 }}
{{- end }}
labels:
app: {{ template "superset.name" . }}
release: {{ .Release.Name }}

View File

@ -163,6 +163,12 @@ supersetNode:
name: '{{ tpl .Values.envFromSecret . }}'
command: [ "/bin/sh", "-c", "until nc -zv $DB_HOST $DB_PORT -w1; do echo 'waiting for db'; sleep 1; done" ]
## Annotations to be added to supersetNode deployment
deploymentAnnotations: {}
## Annotations to be added to supersetNode pods
podAnnotations: {}
##
## Superset worker configuration
supersetWorker:
@ -180,6 +186,12 @@ supersetWorker:
name: '{{ tpl .Values.envFromSecret . }}'
command: [ "/bin/sh", "-c", "until nc -zv $DB_HOST $DB_PORT -w1; do echo 'waiting for db'; sleep 1; done" ]
## Annotations to be added to supersetWorker deployment
deploymentAnnotations: {}
## Annotations to be added to supersetWorker pods
podAnnotations: {}
##
## Superset beat configuration (to trigger scheduled jobs like reports)
supersetCeleryBeat:
@ -199,6 +211,12 @@ supersetCeleryBeat:
name: '{{ tpl .Values.envFromSecret . }}'
command: [ "/bin/sh", "-c", "until nc -zv $DB_HOST $DB_PORT -w1; do echo 'waiting for db'; sleep 1; done" ]
## Annotations to be added to supersetCeleryBeat deployment
deploymentAnnotations: {}
## Annotations to be added to supersetCeleryBeat pods
podAnnotations: {}
##
## Init job configuration
init: