diff --git a/Chart.yaml b/Chart.yaml index cf68afc..8d078ca 100644 --- a/Chart.yaml +++ b/Chart.yaml @@ -15,7 +15,7 @@ type: application # This is the chart version. This version number should be incremented each time # you make changes to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 5.3.3 +version: 5.4.0 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to diff --git a/templates/deployment-sidekiq.yaml b/templates/deployment-sidekiq.yaml index 8898715..0fcb239 100644 --- a/templates/deployment-sidekiq.yaml +++ b/templates/deployment-sidekiq.yaml @@ -7,12 +7,18 @@ metadata: name: {{ include "mastodon.fullname" $context }}-sidekiq-{{ .name }} labels: {{- include "mastodon.labels" $context | nindent 4 }} + {{- with $context.Values.mastodon.sidekiq.labels }} + {{- toYaml . | nindent 4 }} + {{- end }} app.kubernetes.io/component: sidekiq-{{ .name }} app.kubernetes.io/part-of: rails annotations: {{- with $context.Values.deploymentAnnotations }} {{- toYaml . | nindent 4 }} {{- end }} + {{- with $context.Values.mastodon.sidekiq.annotations }} + {{- toYaml . | nindent 4 }} + {{- end }} spec: {{- if (has "scheduler" .queues) }} {{- if (gt (int .replicas) 1) }} @@ -37,6 +43,9 @@ spec: {{- with $context.Values.podAnnotations }} {{- toYaml . | nindent 8 }} {{- end }} + {{- with $context.Values.mastodon.sidekiq.podAnnotations }} + {{- toYaml . | nindent 8 }} + {{- end }} # roll the pods to pick up any db migrations or other changes {{- include "mastodon.rollingPodAnnotations" $context | nindent 8 }} checksum/config-secrets-smtp: {{ include ( print $.Template.BasePath "/secret-smtp.yaml" ) $context | sha256sum | quote }} @@ -44,6 +53,9 @@ spec: {{- include "mastodon.globalLabels" $context | nindent 8 }} {{- include "mastodon.selectorLabels" $context | nindent 8 }} {{- include "mastodon.statsdExporterLabels" $context | nindent 8 }} + {{- with $context.Values.mastodon.sidekiq.podLabels }} + {{- toYaml . | nindent 8 }} + {{- end }} app.kubernetes.io/component: sidekiq-{{ .name }} app.kubernetes.io/part-of: rails spec: diff --git a/templates/deployment-streaming.yaml b/templates/deployment-streaming.yaml index 89bd06a..9f4a6b9 100644 --- a/templates/deployment-streaming.yaml +++ b/templates/deployment-streaming.yaml @@ -4,8 +4,14 @@ metadata: name: {{ include "mastodon.fullname" . }}-streaming labels: {{- include "mastodon.labels" . | nindent 4 }} + {{- with .Values.mastodon.streaming.labels }} + {{- toYaml . | nindent 4 }} + {{- end }} annotations: - {{- with (default .Values.deploymentAnnotations .Values.mastodon.streaming.deploymentAnnotations) }} + {{- with .Values.deploymentAnnotations }} + {{- toYaml . | nindent 4 }} + {{- end }} + {{- with .Values.mastodon.streaming.annotations }} {{- toYaml . | nindent 4 }} {{- end }} spec: @@ -13,8 +19,8 @@ spec: {{- if (ne (toString .Values.mastodon.revisionHistoryLimit) "") }} revisionHistoryLimit: {{ .Values.mastodon.revisionHistoryLimit }} {{- end }} - {{- if .Values.mastodon.web.updateStrategy }} - strategy: {{- toYaml .Values.mastodon.web.updateStrategy | nindent 4 }} + {{- if .Values.mastodon.streaming.updateStrategy }} + strategy: {{- toYaml .Values.mastodon.streaming.updateStrategy | nindent 4 }} {{- end }} selector: matchLabels: @@ -23,7 +29,10 @@ spec: template: metadata: annotations: - {{- with (default .Values.podAnnotations .Values.mastodon.streaming.podAnnotations) }} + {{- with .Values.podAnnotations }} + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.mastodon.streaming.podAnnotations }} {{- toYaml . | nindent 8 }} {{- end }} # roll the pods to pick up any db migrations or other changes @@ -31,6 +40,9 @@ spec: labels: {{- include "mastodon.globalLabels" . | nindent 8 }} {{- include "mastodon.selectorLabels" . | nindent 8 }} + {{- with .Values.mastodon.streaming.podLabels }} + {{- toYaml . | nindent 8 }} + {{- end }} app.kubernetes.io/component: streaming spec: {{- with .Values.imagePullSecrets }} diff --git a/templates/deployment-web.yaml b/templates/deployment-web.yaml index b3a2620..c7b288f 100644 --- a/templates/deployment-web.yaml +++ b/templates/deployment-web.yaml @@ -4,8 +4,14 @@ metadata: name: {{ include "mastodon.fullname" . }}-web labels: {{- include "mastodon.labels" . | nindent 4 }} + {{- with .Values.mastodon.web.labels }} + {{- toYaml . | nindent 4 }} + {{- end }} annotations: - {{- with (default .Values.deploymentAnnotations .Values.mastodon.web.deploymentAnnotations) }} + {{- with .Values.deploymentAnnotations }} + {{- toYaml . | nindent 4 }} + {{- end }} + {{- with .Values.mastodon.web.annotations }} {{- toYaml . | nindent 4 }} {{- end }} spec: @@ -24,7 +30,10 @@ spec: template: metadata: annotations: - {{- with (default .Values.podAnnotations .Values.mastodon.web.podAnnotations) }} + {{- with .Values.podAnnotations }} + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.mastodon.web.podAnnotations }} {{- toYaml . | nindent 8 }} {{- end }} # roll the pods to pick up any db migrations or other changes @@ -33,6 +42,9 @@ spec: {{- include "mastodon.globalLabels" . | nindent 8 }} {{- include "mastodon.selectorLabels" . | nindent 8 }} {{- include "mastodon.statsdExporterLabels" . | nindent 8 }} + {{- with .Values.mastodon.web.podLabels }} + {{- toYaml . | nindent 8 }} + {{- end }} app.kubernetes.io/component: web app.kubernetes.io/part-of: rails spec: diff --git a/values.yaml b/values.yaml index f0ea98d..5117a6d 100644 --- a/values.yaml +++ b/values.yaml @@ -141,6 +141,18 @@ mastodon: resources: {} # -- Affinity for all Sidekiq Deployments unless overwritten, overwrites .Values.affinity affinity: {} + # -- Annotations to apply to the deployment object(s) for sidekiq. + # -- These are applied in addition to deploymentAnnotations. + annotations: {} + # -- Labels to apply to the deployment object(s) for sidekiq. + # -- These are applied in addition to mastodon.labels. + labels: {} + # -- Annotations to apply to the sidekiq pods. + # -- These are applied in addition to the global podAnnotations. + podAnnotations: {} + # -- Labels to apply to the sidekiq pods. + # -- These are applied in addition to mastodon.labels. + podLabels: {} # Rollout strategy to use when updating pods. # Recreate will help reduce the number of retried jobs when updating when # the code introduces a new job as the pods are all replaced immediately. @@ -255,6 +267,18 @@ mastodon: replicas: 1 # -- Affinity for Streaming Pods, overwrites .Values.affinity affinity: {} + # -- Annotations to apply to the deployment object for streaming. + # -- These are applied in addition to deploymentAnnotations. + annotations: {} + # -- Labels to apply to the deployment object for streaming. + # -- These are applied in addition to mastodon.labels. + labels: {} + # -- Annotations to apply to the streaming pods. + # -- These are applied in addition to the global podAnnotations. + podAnnotations: {} + # -- Labels to apply to the streaming pods. + # -- These are applied in addition to mastodon.labels. + podLabels: {} # Rollout strategy to use when updating pods # ref: https://kubernetes.io/docs/concepts/workloads/controllers/deployment/#strategy updateStrategy: @@ -301,6 +325,18 @@ mastodon: replicas: 1 # -- Affinity for Web Pods, overwrites .Values.affinity affinity: {} + # -- Annotations to apply to the deployment object for web. + # -- These are applied in addition to deploymentAnnotations. + annotations: {} + # -- Labels to apply to the deployment object for web. + # -- These are applied in addition to mastodon.labels. + labels: {} + # -- Annotations to apply to the web pods. + # -- These are applied in addition to the global podAnnotations. + podAnnotations: {} + # -- Labels to apply to the web pods. + # -- These are applied in addition to mastodon.labels. + podLabels: {} # Rollout strategy to use when updating pods # ref: https://kubernetes.io/docs/concepts/workloads/controllers/deployment/#strategy updateStrategy: