mirror of
https://github.com/mastodon/chart
synced 2025-05-17 20:43:21 +00:00
Adjust nodeselector to default to global value, then rewrite with local values
This commit is contained in:
parent
1b9f6b8028
commit
ca2cd6ff8a
|
@ -110,5 +110,8 @@ spec:
|
||||||
{{- if .Values.mastodon.cron.removeMedia.nodeSelector }}
|
{{- if .Values.mastodon.cron.removeMedia.nodeSelector }}
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
{{ .Values.mastodon.cron.removeMedia.nodeSelector | toYaml | nindent 12 }}
|
{{ .Values.mastodon.cron.removeMedia.nodeSelector | toYaml | nindent 12 }}
|
||||||
|
{{- else if .Values.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.nodeSelector | toYaml | nindent 12 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
|
@ -255,9 +255,15 @@ spec:
|
||||||
resources:
|
resources:
|
||||||
{{- toYaml (default (default $context.Values.resources $context.Values.mastodon.sidekiq.resources) .resources) | nindent 12 }}
|
{{- toYaml (default (default $context.Values.resources $context.Values.mastodon.sidekiq.resources) .resources) | nindent 12 }}
|
||||||
{{- include "mastodon.statsdExporterContainer" $ | indent 8 }}
|
{{- include "mastodon.statsdExporterContainer" $ | indent 8 }}
|
||||||
{{- if $context.Values.mastodon.sidekiq.nodeSelector }}
|
{{- if .nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{- .nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- else if $context.Values.mastodon.sidekiq.nodeSelector }}
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
{{- $context.Values.mastodon.sidekiq.nodeSelector | toYaml | nindent 8 }}
|
{{- $context.Values.mastodon.sidekiq.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- else if $context.Values.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{- $context.Values.nodeSelector | toYaml | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with $context.Values.tolerations }}
|
{{- with $context.Values.tolerations }}
|
||||||
tolerations:
|
tolerations:
|
||||||
|
|
|
@ -164,6 +164,9 @@ spec:
|
||||||
{{- if .Values.mastodon.streaming.nodeSelector }}
|
{{- if .Values.mastodon.streaming.nodeSelector }}
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
{{ .Values.mastodon.streaming.nodeSelector | toYaml | nindent 8 }}
|
{{ .Values.mastodon.streaming.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- else if .Values.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.nodeSelector | toYaml | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with (default .Values.affinity .Values.mastodon.streaming.affinity) }}
|
{{- with (default .Values.affinity .Values.mastodon.streaming.affinity) }}
|
||||||
affinity:
|
affinity:
|
||||||
|
|
|
@ -272,6 +272,9 @@ spec:
|
||||||
{{- if .Values.mastodon.web.nodeSelector }}
|
{{- if .Values.mastodon.web.nodeSelector }}
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
{{ .Values.mastodon.web.nodeSelector | toYaml | nindent 8 }}
|
{{ .Values.mastodon.web.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- else if .Values.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.nodeSelector | toYaml | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with (default .Values.affinity .Values.mastodon.web.affinity) }}
|
{{- with (default .Values.affinity .Values.mastodon.web.affinity) }}
|
||||||
affinity:
|
affinity:
|
||||||
|
|
|
@ -89,4 +89,12 @@ spec:
|
||||||
volumes:
|
volumes:
|
||||||
- name: assets
|
- name: assets
|
||||||
emptyDir: {}
|
emptyDir: {}
|
||||||
|
{{- if .Values.mastodon.hooks.s3Upload.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.mastodon.hooks.s3Upload.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- else if .Values.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
|
@ -98,5 +98,8 @@ spec:
|
||||||
{{- if .Values.mastodon.createAdmin.nodeSelector }}
|
{{- if .Values.mastodon.createAdmin.nodeSelector }}
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
{{ .Values.mastodon.createAdmin.nodeSelector | toYaml | nindent 8 }}
|
{{ .Values.mastodon.createAdmin.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- else if .Values.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.nodeSelector | toYaml | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
|
@ -1,3 +1,10 @@
|
||||||
{{- if .Values.mastodon.hooks.dbMigrate.enabled }}
|
{{- if .Values.mastodon.hooks.dbMigrate.enabled }}
|
||||||
{{- include "mastodon.dbMigrateJob" (merge (dict "preDeploy" false ) .) }}
|
{{- include "mastodon.dbMigrateJob" (merge (dict "preDeploy" false ) .) }}
|
||||||
|
{{- if .Values.mastodon.hooks.dbMigrate.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.mastodon.hooks.dbMigrate.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- else if .Values.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
|
@ -1,3 +1,10 @@
|
||||||
{{- if .Values.mastodon.hooks.dbMigrate.enabled }}
|
{{- if .Values.mastodon.hooks.dbMigrate.enabled }}
|
||||||
{{- include "mastodon.dbMigrateJob" (merge (dict "preDeploy" true ) .) }}
|
{{- include "mastodon.dbMigrateJob" (merge (dict "preDeploy" true ) .) }}
|
||||||
|
{{- if .Values.mastodon.hooks.dbMigrate.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.mastodon.hooks.dbMigrate.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- else if .Values.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
|
@ -1,3 +1,10 @@
|
||||||
{{- if and .Values.mastodon.hooks.dbPrepare.enabled (not .Values.postgresql.enabled) }}
|
{{- if and .Values.mastodon.hooks.dbPrepare.enabled (not .Values.postgresql.enabled) }}
|
||||||
{{- include "mastodon.dbMigrateJob" (merge (dict "prepare" true ) .) }}
|
{{- include "mastodon.dbMigrateJob" (merge (dict "prepare" true ) .) }}
|
||||||
|
{{- if .Values.mastodon.hooks.dbPrepare.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.mastodon.hooks.dbPrepare.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- else if .Values.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ .Values.nodeSelector | toYaml | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user