Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Merged
merged 1 commit into from
Apr 9, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions helm/superset/templates/deployment-beat.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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 }}
Expand Down
7 changes: 7 additions & 0 deletions helm/superset/templates/deployment-worker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand All @@ -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 }}
Expand Down
7 changes: 7 additions & 0 deletions helm/superset/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand All @@ -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 }}
Expand Down
18 changes: 18 additions & 0 deletions helm/superset/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand All @@ -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:
Expand All @@ -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:
Expand Down