diff --git a/charts/synapse/source/values.schema.json b/charts/synapse/source/values.schema.json index 4b1b2233..9309afbc 100644 --- a/charts/synapse/source/values.schema.json +++ b/charts/synapse/source/values.schema.json @@ -3,208 +3,119 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { - "enabled": { - "type": "boolean" - }, - "postgres": { - "$ref": "file://./../../matrix-stack/sub_schemas/postgres-libpq.json" - }, - "media": { - "type": "object", - "properties": { - "storage": { - "$ref": "file://./../../matrix-stack/sub_schemas/persistentVolumeClaim.json" - } - } - }, - "macaroon": { - "$ref": "file://./../../matrix-stack/sub_schemas/credential.json" - }, - "registrationSharedSecret": { - "$ref": "file://./../../matrix-stack/sub_schemas/credential.json" - }, - "signingKey": { - "$ref": "file://./../../matrix-stack/sub_schemas/credential.json" - }, - "additional": { - "type": "object", - "anyOf": [ - { - "required": [] - }, - { - "required": [ - "config" - ] - }, - { - "required": [ - "configSecret", - "configSecretKey" - ] - } - ], - "properties": { - "config": { - "type": "string" - }, - "configSecret": { - "type": "string" - }, - "configSecretKey": { - "type": "string" - } - } - }, - "appservices": { - "type": "array", - "items": { - "type": "object", - "properties": { - "registrationFileConfigMap": { - "type": "string" - } - } - } - }, - "logging": { - "type": "object", - "properties": { - "rootLevel": { - "type": "string", - "enum": [ - "CRITICAL", - "ERROR", - "WARNING", - "INFO", - "DEBUG" - ] - }, - "levelOverrides": { - "type": "object", - "additionalProperties": { - "type": "string", - "enum": [ - "CRITICAL", - "ERROR", - "WARNING", - "INFO", - "DEBUG" - ] - } - } - } - }, "global": { "$ref": "file://./../../matrix-stack/sub_schemas/global.json" }, + "ess": { + "$ref": "file://./../../matrix-stack/sub_schemas/ess.json" + }, "ess-library": { - "$ref": "file://./../../matrix-stack/sub_schemas/essLibrary.json" + "type": "object", + "additionalProperties": true }, - "ingress": { - "$ref": "file://sub_schemas/ingress_with_additional_paths.json" - }, - "image": { - "$ref": "file://./../../matrix-stack/sub_schemas/image.json" - }, - "labels": { - "$ref": "file://./../../matrix-stack/sub_schemas/labels.json" - }, - "annotations": { - "$ref": "file://./../../matrix-stack/sub_schemas/workloadAnnotations.json" - }, - "containersSecurityContext": { - "$ref": "file://./../../matrix-stack/sub_schemas/containersSecurityContext.json" - }, - "extraEnv": { - "$ref": "file://./../../matrix-stack/sub_schemas/extraEnv.json" - }, - "hostAliases": { - "$ref": "file://./../../matrix-stack/sub_schemas/hostAliases.json" - }, - "nodeSelector": { - "$ref": "file://./../../matrix-stack/sub_schemas/nodeSelector.json" - }, - "podSecurityContext": { - "$ref": "file://./../../matrix-stack/sub_schemas/podSecurityContext.json" - }, - "resources": { - "$ref": "file://./../../matrix-stack/sub_schemas/resources.json" - }, - "serviceAccount": { - "$ref": "file://./../../matrix-stack/sub_schemas/serviceAccount.json" - }, - "serviceMonitors": { - "$ref": "file://./../../matrix-stack/sub_schemas/serviceMonitors.json" - }, - "tolerations": { - "$ref": "file://./../../matrix-stack/sub_schemas/tolerations.json" - }, - "workers": { + "synapse": { "type": "object", "properties": { - "appservice": { - "$ref": "file://sub_schemas/single_worker.json" + "enabled": { + "type": "boolean" }, - "background": { - "$ref": "file://sub_schemas/single_worker.json" + "postgres": { + "$ref": "file://./../../matrix-stack/sub_schemas/postgres-libpq.json" }, - "client-reader": { - "$ref": "file://sub_schemas/scalable_worker.json" + "media": { + "type": "object", + "properties": { + "storage": { + "$ref": "file://./../../matrix-stack/sub_schemas/persistentVolumeClaim.json" + } + } }, - "encryption": { - "$ref": "file://sub_schemas/single_worker.json" + "macaroon": { + "$ref": "file://./../../matrix-stack/sub_schemas/credential.json" }, - "event-creator": { - "$ref": "file://sub_schemas/scalable_worker.json" + "registrationSharedSecret": { + "$ref": "file://./../../matrix-stack/sub_schemas/credential.json" }, - "event-persister": { - "$ref": "file://sub_schemas/scalable_worker.json" + "signingKey": { + "$ref": "file://./../../matrix-stack/sub_schemas/credential.json" }, - "federation-reader": { - "$ref": "file://sub_schemas/scalable_worker.json" + "additional": { + "type": "object", + "anyOf": [ + { + "required": [] + }, + { + "required": [ + "config" + ] + }, + { + "required": [ + "configSecret", + "configSecretKey" + ] + } + ], + "properties": { + "config": { + "type": "string" + }, + "configSecret": { + "type": "string" + }, + "configSecretKey": { + "type": "string" + } + } }, - "federation-sender": { - "$ref": "file://sub_schemas/scalable_worker.json" + "appservices": { + "type": "array", + "items": { + "type": "object", + "properties": { + "registrationFileConfigMap": { + "type": "string" + } + } + } }, - "initial-synchrotron": { - "$ref": "file://sub_schemas/scalable_worker.json" + "logging": { + "type": "object", + "properties": { + "rootLevel": { + "type": "string", + "enum": [ + "CRITICAL", + "ERROR", + "WARNING", + "INFO", + "DEBUG" + ] + }, + "levelOverrides": { + "type": "object", + "additionalProperties": { + "type": "string", + "enum": [ + "CRITICAL", + "ERROR", + "WARNING", + "INFO", + "DEBUG" + ] + } + } + } }, - "media-repository": { - "$ref": "file://sub_schemas/single_worker.json" + "global": { + "$ref": "file://./../../matrix-stack/sub_schemas/global.json" }, - "presence-writer": { - "$ref": "file://sub_schemas/single_worker.json" + "ess-library": { + "$ref": "file://./../../matrix-stack/sub_schemas/essLibrary.json" }, - "pusher": { - "$ref": "file://sub_schemas/scalable_worker.json" - }, - "receipts-account": { - "$ref": "file://sub_schemas/single_worker.json" - }, - "sliding-sync": { - "$ref": "file://sub_schemas/scalable_worker.json" - }, - "sso-login": { - "$ref": "file://sub_schemas/single_worker.json" - }, - "synchrotron": { - "$ref": "file://sub_schemas/scalable_worker.json" - }, - "typing-persister": { - "$ref": "file://sub_schemas/single_worker.json" - }, - "user-dir": { - "$ref": "file://sub_schemas/single_worker.json" - } - } - }, - "haproxy": { - "type": "object", - "properties": { - "replicas": { - "minimum": 1, - "type": "integer" + "ingress": { + "$ref": "file://sub_schemas/ingress_with_additional_paths.json" }, "image": { "$ref": "file://./../../matrix-stack/sub_schemas/image.json" @@ -218,6 +129,12 @@ "containersSecurityContext": { "$ref": "file://./../../matrix-stack/sub_schemas/containersSecurityContext.json" }, + "extraEnv": { + "$ref": "file://./../../matrix-stack/sub_schemas/extraEnv.json" + }, + "hostAliases": { + "$ref": "file://./../../matrix-stack/sub_schemas/hostAliases.json" + }, "nodeSelector": { "$ref": "file://./../../matrix-stack/sub_schemas/nodeSelector.json" }, @@ -235,40 +152,138 @@ }, "tolerations": { "$ref": "file://./../../matrix-stack/sub_schemas/tolerations.json" - } - } - }, - "redis": { - "type": "object", - "properties": { - "image": { - "$ref": "file://./../../matrix-stack/sub_schemas/image.json" }, - "labels": { - "$ref": "file://./../../matrix-stack/sub_schemas/labels.json" + "workers": { + "type": "object", + "properties": { + "appservice": { + "$ref": "file://sub_schemas/single_worker.json" + }, + "background": { + "$ref": "file://sub_schemas/single_worker.json" + }, + "client-reader": { + "$ref": "file://sub_schemas/scalable_worker.json" + }, + "encryption": { + "$ref": "file://sub_schemas/single_worker.json" + }, + "event-creator": { + "$ref": "file://sub_schemas/scalable_worker.json" + }, + "event-persister": { + "$ref": "file://sub_schemas/scalable_worker.json" + }, + "federation-reader": { + "$ref": "file://sub_schemas/scalable_worker.json" + }, + "federation-sender": { + "$ref": "file://sub_schemas/scalable_worker.json" + }, + "initial-synchrotron": { + "$ref": "file://sub_schemas/scalable_worker.json" + }, + "media-repository": { + "$ref": "file://sub_schemas/single_worker.json" + }, + "presence-writer": { + "$ref": "file://sub_schemas/single_worker.json" + }, + "pusher": { + "$ref": "file://sub_schemas/scalable_worker.json" + }, + "receipts-account": { + "$ref": "file://sub_schemas/single_worker.json" + }, + "sliding-sync": { + "$ref": "file://sub_schemas/scalable_worker.json" + }, + "sso-login": { + "$ref": "file://sub_schemas/single_worker.json" + }, + "synchrotron": { + "$ref": "file://sub_schemas/scalable_worker.json" + }, + "typing-persister": { + "$ref": "file://sub_schemas/single_worker.json" + }, + "user-dir": { + "$ref": "file://sub_schemas/single_worker.json" + } + } }, - "annotations": { - "$ref": "file://./../../matrix-stack/sub_schemas/workloadAnnotations.json" + "haproxy": { + "type": "object", + "properties": { + "replicas": { + "minimum": 1, + "type": "integer" + }, + "image": { + "$ref": "file://./../../matrix-stack/sub_schemas/image.json" + }, + "labels": { + "$ref": "file://./../../matrix-stack/sub_schemas/labels.json" + }, + "annotations": { + "$ref": "file://./../../matrix-stack/sub_schemas/workloadAnnotations.json" + }, + "containersSecurityContext": { + "$ref": "file://./../../matrix-stack/sub_schemas/containersSecurityContext.json" + }, + "nodeSelector": { + "$ref": "file://./../../matrix-stack/sub_schemas/nodeSelector.json" + }, + "podSecurityContext": { + "$ref": "file://./../../matrix-stack/sub_schemas/podSecurityContext.json" + }, + "resources": { + "$ref": "file://./../../matrix-stack/sub_schemas/resources.json" + }, + "serviceAccount": { + "$ref": "file://./../../matrix-stack/sub_schemas/serviceAccount.json" + }, + "serviceMonitors": { + "$ref": "file://./../../matrix-stack/sub_schemas/serviceMonitors.json" + }, + "tolerations": { + "$ref": "file://./../../matrix-stack/sub_schemas/tolerations.json" + } + } }, - "containersSecurityContext": { - "$ref": "file://./../../matrix-stack/sub_schemas/containersSecurityContext.json" - }, - "nodeSelector": { - "$ref": "file://./../../matrix-stack/sub_schemas/nodeSelector.json" - }, - "podSecurityContext": { - "$ref": "file://./../../matrix-stack/sub_schemas/podSecurityContext.json" - }, - "resources": { - "$ref": "file://./../../matrix-stack/sub_schemas/resources.json" - }, - "serviceAccount": { - "$ref": "file://./../../matrix-stack/sub_schemas/serviceAccount.json" - }, - "tolerations": { - "$ref": "file://./../../matrix-stack/sub_schemas/tolerations.json" + "redis": { + "type": "object", + "properties": { + "image": { + "$ref": "file://./../../matrix-stack/sub_schemas/image.json" + }, + "labels": { + "$ref": "file://./../../matrix-stack/sub_schemas/labels.json" + }, + "annotations": { + "$ref": "file://./../../matrix-stack/sub_schemas/workloadAnnotations.json" + }, + "containersSecurityContext": { + "$ref": "file://./../../matrix-stack/sub_schemas/containersSecurityContext.json" + }, + "nodeSelector": { + "$ref": "file://./../../matrix-stack/sub_schemas/nodeSelector.json" + }, + "podSecurityContext": { + "$ref": "file://./../../matrix-stack/sub_schemas/podSecurityContext.json" + }, + "resources": { + "$ref": "file://./../../matrix-stack/sub_schemas/resources.json" + }, + "serviceAccount": { + "$ref": "file://./../../matrix-stack/sub_schemas/serviceAccount.json" + }, + "tolerations": { + "$ref": "file://./../../matrix-stack/sub_schemas/tolerations.json" + } + } } } } } -} +} \ No newline at end of file diff --git a/charts/synapse/source/values.yaml.j2 b/charts/synapse/source/values.yaml.j2 index 490fd1d9..0f021093 100644 --- a/charts/synapse/source/values.yaml.j2 +++ b/charts/synapse/source/values.yaml.j2 @@ -6,109 +6,111 @@ SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial {% import 'sub_schema_values.yaml.j2' as sub_schema_values -%} {% import 'synapse_sub_schema_values.yaml.j2' as synapse_sub_schema_values -%} -{{ sub_schema_values.generatedFileWarning() }} +{{- sub_schema_values.generatedFileWarning() }} -{{ sub_schema_values.global() }} +{{- sub_schema_values.ess() }} -{{ sub_schema_values.postgresLibPQ() }} +{{- sub_schema_values.postgresLibPQ() }} -## Configures the media store for Synapse -media: -{{ sub_schema_values.persistentVolumeClaim("storage") | indent(2) }} +synapse: + enabled: true + ## Configures the media store for Synapse + media: + {{- sub_schema_values.persistentVolumeClaim("storage") | indent(4) }} -{{ sub_schema_values.credential("Key used to sign events and federation requests.\n## This needs to be the full signing key starting `ed25519 ...`", "signingKey") }} -{{ sub_schema_values.credential("Shared Secret to registering users without having any users provisioned", "registrationSharedSecret") }} -{{ sub_schema_values.credential("Secret used to sign Synapse issued tokens", "macaroon") }} + {{- sub_schema_values.credential("Key used to sign events and federation requests.\n## This needs to be the full signing key starting `ed25519 ...`", "signingKey") | indent(2) }} + {{- sub_schema_values.credential("Shared Secret to registering users without having any users provisioned", "registrationSharedSecret") | indent(2) }} + {{- sub_schema_values.credential("Secret used to sign Synapse issued tokens", "macaroon") | indent(2) }} -## Additional configuration to provide to all Synapse processes. -## This can be provided in-line in the Helm Chart and/or via an existing Secret -## e.g. -## additional: -## config: | -## allow_guest_access: true -## -## or -## additional: -## configSecret: custom-synapse-config -## configSecretKey: shared.yaml -additional: {} - -## Details of Application Service registration files to give to Synapse -## e.g. -## appservices: -## - registrationFileConfigMap: test-appservice -appservices: [] - -## Additional Synapse processes managed by this chart -## e.g. -## workers: -## client-reader: -## instances: 2 -## event-creator: {} -workers: -{{ synapse_sub_schema_values.single_worker('appservice') | indent(2) }} -{{ synapse_sub_schema_values.single_worker('background') | indent(2) }} -{{ synapse_sub_schema_values.scalable_worker('client-reader') | indent(2) }} -{{ synapse_sub_schema_values.single_worker('encryption') | indent(2) }} -{{ synapse_sub_schema_values.scalable_worker('event-creator') | indent(2) }} -{{ synapse_sub_schema_values.scalable_worker('event-persister') | indent(2) }} -{{ synapse_sub_schema_values.scalable_worker('federation-reader') | indent(2) }} -{{ synapse_sub_schema_values.scalable_worker('federation-sender') | indent(2) }} -{{ synapse_sub_schema_values.scalable_worker('initial-synchrotron') | indent(2) }} -{{ synapse_sub_schema_values.single_worker('media-repository') | indent(2) }} -{{ synapse_sub_schema_values.single_worker('presence-writer') | indent(2) }} -{{ synapse_sub_schema_values.scalable_worker('pusher') | indent(2) }} -{{ synapse_sub_schema_values.single_worker('receipts-account') | indent(2) }} -{{ synapse_sub_schema_values.scalable_worker('sliding-sync') | indent(2) }} -{{ synapse_sub_schema_values.single_worker('sso-login') | indent(2) }} -{{ synapse_sub_schema_values.scalable_worker('synchrotron') | indent(2) }} -{{ synapse_sub_schema_values.single_worker('typing-persister') | indent(2) }} -{{ synapse_sub_schema_values.single_worker('user-dir') | indent(2) }} - -## Synapse's logging settings -logging: - ## The maximum level of Synapse log output before any overrides - rootLevel: INFO - - ## Override the log level of specific loggers + ## Additional configuration to provide to all Synapse processes. + ## This can be provided in-line in the Helm Chart and/or via an existing Secret ## e.g. - ## levelOverrides: - ## synapse.util.caches.lrucache: WARNING - levelOverrides: {} -{{ sub_schema_values.image(registry='docker.io', repository='matrixdotorg/synapse') }} -{{ sub_schema_values.ingress() }} -{{ sub_schema_values.labels() }} -{{ sub_schema_values.workloadAnnotations() }} -{{ sub_schema_values.containersSecurityContext() }} -{{ sub_schema_values.extraEnv() }} -{{ sub_schema_values.hostAliases() }} -{{ sub_schema_values.nodeSelector() }} -{{ sub_schema_values.podSecurityContext(user_id='10091', group_id='10091') }} -{{ sub_schema_values.resources(requests_memory='100Mi', requests_cpu='100m', limits_memory='4Gi') }} -{{ sub_schema_values.serviceAccount() }} -{{ sub_schema_values.serviceMonitors() }} -{{ sub_schema_values.tolerations() }} + ## additional: + ## config: | + ## allow_guest_access: true + ## + ## or + ## additional: + ## configSecret: custom-synapse-config + ## configSecretKey: shared.yaml + additional: {} -haproxy: - replicas: 2 -{{ sub_schema_values.image(registry='docker.io', repository='library/haproxy', tag='3.0-alpine') | indent(2) }} -{{ sub_schema_values.labels() | indent(2) }} -{{ sub_schema_values.workloadAnnotations() | indent(2) }} -{{ sub_schema_values.containersSecurityContext() | indent(2) }} -{{ sub_schema_values.nodeSelector() | indent(2) }} -{{ sub_schema_values.podSecurityContext(user_id='10001', group_id='10001') | indent(2) }} -{{ sub_schema_values.resources(requests_memory='100Mi', requests_cpu='100m', limits_memory='200Mi') | indent(2) }} -{{ sub_schema_values.serviceAccount() | indent(2) }} -{{ sub_schema_values.serviceMonitors() | indent(2) }} -{{ sub_schema_values.tolerations() | indent(2) }} + ## Details of Application Service registration files to give to Synapse + ## e.g. + ## appservices: + ## - registrationFileConfigMap: test-appservice + appservices: [] -redis: -{{- sub_schema_values.image(registry='docker.io', repository='library/redis', tag='7.4-alpine') | indent(2) }} -{{ sub_schema_values.labels() | indent(2) }} -{{ sub_schema_values.workloadAnnotations() | indent(2) }} -{{ sub_schema_values.containersSecurityContext() | indent(2) }} -{{ sub_schema_values.nodeSelector() | indent(2) }} -{{ sub_schema_values.podSecurityContext(user_id='10002', group_id='10002') | indent(2) }} -{{ sub_schema_values.resources(requests_memory='50Mi', requests_cpu='50m', limits_memory='50Mi') | indent(2) }} -{{ sub_schema_values.serviceAccount() | indent(2) }} -{{ sub_schema_values.tolerations() | indent(2) }} + ## Additional Synapse processes managed by this chart + ## e.g. + ## workers: + ## client-reader: + ## instances: 2 + ## event-creator: {} + workers: + {{- synapse_sub_schema_values.single_worker('appservice') | indent(4) }} + {{- synapse_sub_schema_values.single_worker('background') | indent(4) }} + {{- synapse_sub_schema_values.scalable_worker('client-reader') | indent(4) }} + {{- synapse_sub_schema_values.single_worker('encryption') | indent(4) }} + {{- synapse_sub_schema_values.scalable_worker('event-creator') | indent(4) }} + {{- synapse_sub_schema_values.scalable_worker('event-persister') | indent(4) }} + {{- synapse_sub_schema_values.scalable_worker('federation-reader') | indent(4) }} + {{- synapse_sub_schema_values.scalable_worker('federation-sender') | indent(4) }} + {{- synapse_sub_schema_values.scalable_worker('initial-synchrotron') | indent(4) }} + {{- synapse_sub_schema_values.single_worker('media-repository') | indent(4) }} + {{- synapse_sub_schema_values.single_worker('presence-writer') | indent(4) }} + {{- synapse_sub_schema_values.scalable_worker('pusher') | indent(4) }} + {{- synapse_sub_schema_values.single_worker('receipts-account') | indent(4) }} + {{- synapse_sub_schema_values.scalable_worker('sliding-sync') | indent(4) }} + {{- synapse_sub_schema_values.single_worker('sso-login') | indent(4) }} + {{- synapse_sub_schema_values.scalable_worker('synchrotron') | indent(4) }} + {{- synapse_sub_schema_values.single_worker('typing-persister') | indent(4) }} + {{- synapse_sub_schema_values.single_worker('user-dir') | indent(4) }} + + ## Synapse's logging settings + logging: + ## The maximum level of Synapse log output before any overrides + rootLevel: INFO + + ## Override the log level of specific loggers + ## e.g. + ## levelOverrides: + ## synapse.util.caches.lrucache: WARNING + levelOverrides: {} + {{- sub_schema_values.image(registry='docker.io', repository='matrixdotorg/synapse') | indent(2) }} + {{- sub_schema_values.ingress() | indent(2) }} + {{- sub_schema_values.labels() | indent(2) }} + {{- sub_schema_values.workloadAnnotations() | indent(2) }} + {{- sub_schema_values.containersSecurityContext() | indent(2) }} + {{- sub_schema_values.extraEnv() | indent(2) }} + {{- sub_schema_values.hostAliases() | indent(2) }} + {{- sub_schema_values.nodeSelector() | indent(2) }} + {{- sub_schema_values.podSecurityContext(user_id='10091', group_id='10091') | indent(2) }} + {{- sub_schema_values.resources(requests_memory='100Mi', requests_cpu='100m', limits_memory='4Gi') | indent(2) }} + {{- sub_schema_values.serviceAccount() | indent(2) }} + {{- sub_schema_values.serviceMonitors() | indent(2) }} + {{- sub_schema_values.tolerations() | indent(2) }} + + haproxy: + replicas: 2 + {{- sub_schema_values.image(registry='docker.io', repository='library/haproxy', tag='3.0-alpine') | indent(4) }} + {{- sub_schema_values.labels() | indent(4) }} + {{- sub_schema_values.workloadAnnotations() | indent(4) }} + {{- sub_schema_values.containersSecurityContext() | indent(4) }} + {{- sub_schema_values.nodeSelector() | indent(4) }} + {{- sub_schema_values.podSecurityContext(user_id='10001', group_id='10001') | indent(4) }} + {{- sub_schema_values.resources(requests_memory='100Mi', requests_cpu='100m', limits_memory='200Mi') | indent(4) }} + {{- sub_schema_values.serviceAccount() | indent(4) }} + {{- sub_schema_values.serviceMonitors() | indent(4) }} + {{- sub_schema_values.tolerations() | indent(4) }} + + redis: + {{- sub_schema_values.image(registry='docker.io', repository='library/redis', tag='7.4-alpine') | indent(4) }} + {{- sub_schema_values.labels() | indent(4) }} + {{- sub_schema_values.workloadAnnotations() | indent(4) }} + {{- sub_schema_values.containersSecurityContext() | indent(4) }} + {{- sub_schema_values.nodeSelector() | indent(4) }} + {{- sub_schema_values.podSecurityContext(user_id='10002', group_id='10002') | indent(4) }} + {{- sub_schema_values.resources(requests_memory='50Mi', requests_cpu='50m', limits_memory='50Mi') | indent(4) }} + {{- sub_schema_values.serviceAccount() | indent(4) }} + {{- sub_schema_values.tolerations() | indent(4) }} diff --git a/charts/synapse/templates/_helpers.tpl b/charts/synapse/templates/_helpers.tpl index c11a3815..59329a74 100644 --- a/charts/synapse/templates/_helpers.tpl +++ b/charts/synapse/templates/_helpers.tpl @@ -1,69 +1,98 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd + +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} {{- define "element-io.synapse.labels" -}} -{{ include "element-io.ess-library.labels.common" (list $ .Values.labels) }} +{{- $global := .global -}} +{{- with required "element-io.synapse.labels missing context" .context -}} +{{ include "element-io.ess-library.labels.common" (list $global .labels) }} app.kubernetes.io/component: matrix-server app.kubernetes.io/name: synapse -app.kubernetes.io/instance: {{ .Release.Name }}-synapse -app.kubernetes.io/version: {{ .Values.image.tag | default $.Chart.AppVersion }} -k8s.element.io/synapse-instance: {{ .Release.Name }}-synapse +app.kubernetes.io/instance: {{ $global.Release.Name }}-synapse +app.kubernetes.io/version: {{ .image.tag | default $global.Chart.AppVersion }} +k8s.element.io/synapse-instance: {{ $global.Release.Name }}-synapse +{{- end }} {{- end }} {{- define "element-io.synapse.process.labels" -}} -{{ include "element-io.ess-library.labels.common" (list $ .Values.labels) }} +{{- $global := .global -}} +{{- with required "element-io.synapse.labels missing context" .context -}} +{{ include "element-io.ess-library.labels.common" (list $ .labels) }} app.kubernetes.io/component: matrix-server app.kubernetes.io/name: synapse-{{ .ProcessType }} -app.kubernetes.io/instance: {{ .Release.Name }}-synapse-{{ .ProcessType }} -app.kubernetes.io/version: {{ .Values.image.tag | default $.Chart.AppVersion }} -k8s.element.io/synapse-instance: {{ .Release.Name }}-synapse +app.kubernetes.io/instance: {{ $global.Name }}-synapse-{{ .ProcessType }} +app.kubernetes.io/version: {{ .image.tag | default $.Chart.AppVersion }} +k8s.element.io/synapse-instance: {{ $global.Name }}-synapse +{{- end }} {{- end }} {{- define "element-io.synapse.redis.labels" -}} -{{ include "element-io.ess-library.labels.common" (list $ .Values.redis.labels) }} +{{- $global := .global -}} +{{- with required "element-io.redis.labels missing context" .context -}} +{{ include "element-io.ess-library.labels.common" (list $ .redis.labels) }} app.kubernetes.io/part-of: matrix-stack app.kubernetes.io/component: matrix-server-pubsub app.kubernetes.io/name: synapse-redis -app.kubernetes.io/instance: {{ .Release.Name }}-synapse-redis -app.kubernetes.io/version: {{ .Values.redis.image.tag }} +app.kubernetes.io/instance: {{ $global.Name }}-synapse-redis +app.kubernetes.io/version: {{ .redis.image.tag }} +{{- end }} {{- end }} {{- define "element-io.synapse.haproxy.labels" -}} -{{ include "element-io.ess-library.labels.common" (list $ .Values.haproxy.labels) }} +{{- $global := .global -}} +{{- with required "element-io.haproxy.labels missing context" .context -}} +{{ include "element-io.ess-library.labels.common" (list $ .haproxy.labels) }} app.kubernetes.io/part-of: matrix-stack app.kubernetes.io/component: matrix-server-ingress app.kubernetes.io/name: synapse-haproxy -app.kubernetes.io/instance: {{ .Release.Name }}-synapse-haproxy -app.kubernetes.io/version: {{ .Values.haproxy.image.tag }} +app.kubernetes.io/instance: {{ $global.Name }}-synapse-haproxy +app.kubernetes.io/version: {{ .haproxy.image.tag }} +{{- end }} {{- end }} {{- define "element-io.synapse.serviceAccountName" -}} -{{ default (printf "%s-synapse" .Release.Name ) .Values.serviceAccount.name }} +{{- $global := .global -}} +{{- with required "element-io.synapse.serviceAccountName missing context" .context -}} +{{ default (printf "%s-synapse" $global.Name ) .serviceAccount.name }} +{{- end }} {{- end }} {{- define "element-io.synapse.redis.serviceAccountName" -}} -{{ default (printf "%s-synapse-redis" .Release.Name ) .Values.redis.serviceAccount.name }} +{{- $global := .global -}} +{{- with required "element-io.synapse.redis.serviceAccountName missing context" .context -}} +{{ default (printf "%s-synapse-redis" $global.Name ) .redis.serviceAccount.name }} +{{- end }} {{- end }} {{- define "element-io.synapse.haproxy.serviceAccountName" -}} -{{ default (printf "%s-synapse-haproxy" .Release.Name ) .Values.haproxy.serviceAccount.name }} +{{- $global := .global -}} +{{- with required "element-io.synapse.haproxy.serviceAccountName missing context" .context -}} +{{ default (printf "%s-synapse-haproxy" $global.Name ) .haproxy.serviceAccount.name }} +{{- end }} {{- end }} {{- define "element-io.synapse.enabledWorkers" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.enabledWorkers missing context" .context -}} {{ $enabledWorkers := dict }} -{{- range $workerType, $workerDetails := .Values.workers }} +{{- range $workerType, $workerDetails := .workers }} {{- if $workerDetails.enabled }} {{ $_ := set $enabledWorkers $workerType $workerDetails }} {{- end }} {{- end }} {{ $enabledWorkers | toJson }} {{- end }} +{{- end }} {{- define "element-io.synapse.pvcName" -}} -{{- if .Values.media.storage.existingClaim -}} -{{ .Values.media.storage.existingClaim }} +{{- $global := .global -}} +{{- with required "element-io.synapse.pvcName missing context" .context -}} +{{- if .media.storage.existingClaim -}} +{{ .media.storage.existingClaim }} {{- else -}} -{{ .Release.Name }}-synapse-media +{{ $global.Name }}-synapse-media {{- end -}} {{- end }} +{{- end }} diff --git a/charts/synapse/templates/_synapse_config.tpl b/charts/synapse/templates/_synapse_config.tpl index 8babfc2f..a6845f12 100644 --- a/charts/synapse/templates/_synapse_config.tpl +++ b/charts/synapse/templates/_synapse_config.tpl @@ -1,17 +1,24 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd + +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} {{- define "element-io.synapse.config.shared-underrides" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.config.shared-underrides missing context" .context -}} report_stats: false require_auth_for_profile_requests: true {{ end }} +{{ end }} {{- define "element-io.synapse.config.shared-overrides" -}} -public_baseurl: https://{{ .Values.ingress.host }} -server_name: {{ required "Synapse requires global.ess.server_name set" .Values.global.ess.server_name }} -signing_key_path: /secrets/{{ $.Values.signingKey.secret | default (printf "%s-synapse" $.Release.Name) }}/{{ $.Values.signingKey.secretKey | default "SIGNING_KEY" }} +{{- $global := .global -}} +{{- with required "element-io.synapse.config.shared-overrides missing context" .context -}} +public_baseurl: https://{{ .ingress.host }} +server_name: {{ required "Synapse requires global.ess.server_name set" .global.ess.server_name }} +signing_key_path: /secrets/{{ .signingKey.secret | default (printf "%s-synapse" $global.Release.Name) }}/{{ .signingKey.secretKey | default "SIGNING_KEY" }} enable_metrics: true log_config: "/conf/log_config.yaml" macaroon_secret_key: ${SYNAPSE_MACAROON} @@ -20,14 +27,14 @@ registration_shared_secret: ${SYNAPSE_REGISTRATION_SHARED_SECRET} database: name: psycopg2 args: - user: {{ .Values.postgres.user }} + user: {{ .postgres.user }} password: ${SYNAPSE_POSTGRES_PASSWORD} - database: {{ .Values.postgres.database }} - host: {{ .Values.postgres.host }} - port: {{ .Values.postgres.port }} + database: {{ .postgres.database }} + host: {{ .postgres.host }} + port: {{ .postgres.port }} application_name: ${APPLICATION_NAME} - sslmode: {{ .Values.postgres.sslMode }} + sslmode: {{ .postgres.sslMode }} keepalives: 1 keepalives_idle: 10 keepalives_interval: 10 @@ -55,28 +62,28 @@ ip_range_blacklist: - 'ff00::/8' - 'fec0::/10' -{{- if dig "appservice" "enabled" false .Values.workers }} +{{- if dig "appservice" "enabled" false .workers }} notify_appservices_from_worker: appservice-0 {{- end }} -{{- with .Values.appservices }} +{{- with .appservices }} app_service_config_files: {{- range $appservice := . }} - /as/{{ .registrationFileConfigMapName }}/registration.yaml {{- end }} {{- end }} -{{- if dig "background" "enabled" false .Values.workers }} +{{- if dig "background" "enabled" false .workers }} run_background_tasks_on: background-0 {{- end }} -{{- if dig "federation-sender" "enabled" false .Values.workers }} +{{- if dig "federation-sender" "enabled" false .workers }} send_federation: false federation_sender_instances: -{{- range $index := untilStep 0 ((index .Values.workers "federation-sender").instances | int) 1 }} +{{- range $index := untilStep 0 ((index .workers "federation-sender").instances | int) 1 }} - federation-sender-{{ $index }} {{- end }} {{- else }} @@ -86,18 +93,18 @@ send_federation: true # This is still required despite media_storage_providers as otherwise Synapse attempts to mkdir /media_store media_store_path: "/media/media_store" -{{- if dig "media-repository" "enabled" false .Values.workers }} +{{- if dig "media-repository" "enabled" false .workers }} media_instance_running_background_jobs: "media-repository-0" {{- end }} presence: - enabled: {{ dig "presence-writer" "enabled" false .Values.workers }} + enabled: {{ dig "presence-writer" "enabled" false .workers }} -{{- if dig "pusher" "enabled" false .Values.workers }} +{{- if dig "pusher" "enabled" false .workers }} start_pushers: false pusher_instances: -{{- range $index := untilStep 0 ((index .Values.workers "pusher").instances | int) 1 }} +{{- range $index := untilStep 0 ((index .workers "pusher").instances | int) 1 }} - pusher-{{ $index }} {{- end }} {{- else }} @@ -105,21 +112,21 @@ pusher_instances: start_pushers: true {{- end }} -{{- if dig "user-dir" "enabled" false .Values.workers }} +{{- if dig "user-dir" "enabled" false .workers }} update_user_directory_from_worker: user-dir-0 {{- end }} -{{- $enabledWorkers := (include "element-io.synapse.enabledWorkers" $) | fromJson }} +{{- $enabledWorkers := (include "element-io.synapse.enabledWorkers" (dict "global" $global "context" .)) | fromJson }} instance_map: main: - host: {{ $.Release.Name }}-synapse-main.{{ $.Release.Namespace }}.svc.cluster.local. + host: {{ $global.Release.Name }}-synapse-main.{{ $global.Release.Namespace }}.svc.cluster.local. port: 9093 {{- range $workerType, $workerDetails := $enabledWorkers }} -{{- if include "element-io.synapse.process.hasReplication" $workerType }} +{{- if include "element-io.synapse.process.hasReplication" (dict "global" $global "context" $workerType) }} {{- range $index := untilStep 0 ($workerDetails.instances | int | default 1) 1 }} {{ $workerType }}-{{ $index }}: - host: {{ $.Release.Name }}-synapse-{{ $workerType }}-{{ $index }}.{{ $.Release.Name }}-synapse-{{ $workerType }}.{{ $.Release.Namespace }}.svc.cluster.local. + host: {{ $global.Release.Name }}-synapse-{{ $workerType }}-{{ $index }}.{{ $global.Release.Name }}-synapse-{{ $workerType }}.{{ $global.Release.Namespace }}.svc.cluster.local. port: 9093 {{- end }} {{- end }} @@ -129,13 +136,13 @@ instance_map: redis: enabled: true - host: "{{ $.Release.Name }}-synapse-redis.{{ $.Release.Namespace }}.svc.cluster.local" -{{- if include "element-io.synapse.streamWriterWorkers" $ | fromJsonArray }} + host: "{{ $global.Release.Name }}-synapse-redis.{{ $global.Release.Namespace }}.svc.cluster.local" +{{- if include "element-io.synapse.streamWriterWorkers" (dict "global" $global "context" .) | fromJsonArray }} stream_writers: {{- range $workerType, $workerDetails := $enabledWorkers }} -{{- if include "element-io.synapse.process.streamWriters" $workerType | fromJsonArray }} -{{- range $stream_writer := include "element-io.synapse.process.streamWriters" $workerType | fromJsonArray }} +{{- if include "element-io.synapse.process.streamWriters" (dict "global" $global "context" $workerType) | fromJsonArray }} +{{- range $stream_writer := include "element-io.synapse.process.streamWriters" (dict "global" $global "context" $workerType) | fromJsonArray }} {{ $stream_writer }}: {{- range $index := untilStep 0 ($workerDetails.instances | int | default 1) 1 }} - {{ $workerType }}-{{ $index }} @@ -145,12 +152,15 @@ stream_writers: {{- end }} {{- end }} {{- end }} +{{- end }} {{ end }} {{- define "element-io.synapse.config.processSpecific" -}} -worker_app: {{ include "element-io.synapse.process.app" .processType }} +{{- $global := .global -}} +{{- with required "element-io.synapse.config.processSpecific missing context" .context -}} +worker_app: {{ include "element-io.synapse.process.app" (dict "global" $global "context" .processType) }} {{- if eq .processType "main" }} listeners: @@ -159,7 +169,7 @@ worker_name: ${APPLICATION_NAME} worker_listeners: {{- end }} -{{- if (include "element-io.synapse.process.hasHttp" .processType) }} +{{- if (include "element-io.synapse.process.hasHttp" (dict "global" $global "context" .processType)) }} - port: 8008 tls: false bind_addresses: ['0.0.0.0'] @@ -175,7 +185,7 @@ worker_listeners: {{- end }} compress: false {{- end }} -{{- if (include "element-io.synapse.process.hasReplication" .processType) }} +{{- if (include "element-io.synapse.process.hasReplication" (dict "global" $global "context" .processType)) }} - port: 9093 tls: false bind_addresses: ['0.0.0.0'] @@ -198,8 +208,8 @@ worker_listeners: - names: [] compress: false -{{- $enabledWorkers := (include "element-io.synapse.enabledWorkers" $) | fromJson }} -{{- if (include "element-io.synapse.process.responsibleForMedia" (dict "processType" .processType "enabledWorkerTypes" (keys $enabledWorkers))) }} +{{- $enabledWorkers := (include "element-io.synapse.enabledWorkers" (dict "global" $global "context" .)) | fromJson }} +{{- if (include "element-io.synapse.process.responsibleForMedia" (dict "global" $global "context" (dict "processType" .processType "enabledWorkerTypes" (keys $enabledWorkers)))) }} enable_media_repo: true {{- else }} # Stub out the media storage provider for processes not responsible for media @@ -211,4 +221,5 @@ media_storage_providers: config: directory: "/media/media_store" {{- end }} +{{- end }} {{ end }} diff --git a/charts/synapse/templates/_synapse_details.tpl b/charts/synapse/templates/_synapse_details.tpl index 75c277b0..1f2d93c1 100644 --- a/charts/synapse/templates/_synapse_details.tpl +++ b/charts/synapse/templates/_synapse_details.tpl @@ -1,8 +1,12 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd + +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} {{- define "element-io.synapse.process.hasHttp" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.process.hasHttp missing context" .context -}} {{ $hasHttp := (list "main" "client-reader" "encryption" "event-creator" "federation-inbound" "federation-reader" "initial-synchrotron" "media-repository" "presence-writer" "receipts-account" @@ -11,35 +15,47 @@ {{- if has . $hasHttp -}} hasHttp {{- end -}} +{{- end -}} {{- end }} {{- define "element-io.synapse.process.hasReplication" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.process.hasReplication missing context" .context -}} {{- $hasReplication := (list "main" "encryption" "event-persister" "presence-writer" "receipts-account" "typing-persister") }} {{- if has . $hasReplication -}} hasReplication {{- end -}} +{{- end -}} {{- end }} {{- define "element-io.synapse.process.isSingle" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.process.isSingle missing context" .context -}} {{ $isSingle := (list "main" "appservice" "background" "encryption" "media-repository" "presence-writer" "receipts-account" "sso-login" "typing-persister" "user-dir") }} {{- if has . $isSingle -}} isSingle {{- end -}} +{{- end -}} {{- end }} {{- define "element-io.synapse.process.workerTypeName" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.process.workerTypeName missing context" .context -}} {{- if eq . "initial-synchrotron" -}} initial-sync {{- else -}} {{ . }} {{- end -}} +{{- end -}} {{- end }} {{- define "element-io.synapse.process.app" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.process.app missing context" .context -}} {{- if eq . "main" -}} synapse.app.homeserver {{- else if eq . "media-repository" -}} @@ -47,17 +63,23 @@ synapse.app.media_repository {{- else -}} synapse.app.generic_worker {{- end -}} +{{- end -}} {{- end }} {{- define "element-io.synapse.process.responsibleForMedia" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.process.responsibleForMedia missing context" .context -}} {{- if and (eq .processType "main") (not (has "media-repository" .enabledWorkerTypes)) -}} responsibleForMedia {{- else if eq .processType "media-repository" -}} responsibleForMedia {{- end -}} +{{- end -}} {{- end }} {{- define "element-io.synapse.process.streamWriters" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.process.streamWriters missing context" .context -}} {{- if eq . "encryption" }} {{ list "to_device" | toJson }} {{- else if eq . "event-persister" }} @@ -72,18 +94,24 @@ responsibleForMedia {{ list | toJson }} {{- end }} {{- end }} +{{- end }} {{- define "element-io.synapse.streamWriterWorkers" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.streamWriterWorkers missing context" .context -}} {{ $streamWriterWorkers := list }} -{{- range $workerType := keys ((include "element-io.synapse.enabledWorkers" $) | fromJson) }} -{{- if include "element-io.synapse.process.streamWriters" $workerType | fromJsonArray -}} +{{- range $workerType := keys ((include "element-io.synapse.enabledWorkers" (dict "global" $global "context" .)) | fromJson) }} +{{- if include "element-io.synapse.process.streamWriters" (dict "global" $global "context" $workerType) | fromJsonArray -}} {{ $streamWriterWorkers = append $streamWriterWorkers $workerType }} {{- end }} {{- end }} {{ $streamWriterWorkers | toJson }} {{- end }} +{{- end }} {{- define "element-io.synapse.configSecrets" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.configSecrets missing context" .context -}} {{ $configSecrets := list (printf "%s-synapse" $.Release.Name) }} {{- with .Values.macaroon.secret -}} {{ $configSecrets = append $configSecrets . }} @@ -99,8 +127,11 @@ responsibleForMedia {{- end -}} {{ $configSecrets | uniq | toJson }} {{- end }} +{{- end }} {{- define "element-io.synapse.process.workerPaths" -}} +{{- $global := .global -}} +{{- with required "element-io.synapse.workerPaths missing context" .context -}} {{ $workerPaths := list }} {{- if eq .workerType "client-reader" }} @@ -298,3 +329,4 @@ responsibleForMedia {{- end }} {{ $workerPaths | toJson }} {{- end }} +{{- end }} diff --git a/charts/synapse/templates/haproxy_configmap.yaml b/charts/synapse/templates/haproxy_configmap.yaml index bb353ab2..85277ac1 100644 --- a/charts/synapse/templates/haproxy_configmap.yaml +++ b/charts/synapse/templates/haproxy_configmap.yaml @@ -1,14 +1,18 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} apiVersion: v1 kind: ConfigMap metadata: labels: - {{- include "element-io.synapse.haproxy.labels" $ | nindent 4 }} - name: {{ .Release.Name }}-synapse-haproxy - namespace: {{ .Release.Namespace }} + {{- include "element-io.synapse.haproxy.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ $.Release.Name }}-synapse-haproxy + namespace: {{ $.Release.Namespace }} data: haproxy.cfg: | {{- tpl ($.Files.Get "configs/haproxy/haproxy.cfg.tpl") . | nindent 4 }} @@ -16,9 +20,9 @@ data: # A map file that is used in haproxy config to map from matrix paths to the # named backend. The format is: path_regexp backend_name - {{ $enabledWorkerTypes := keys ((include "element-io.synapse.enabledWorkers" $) | fromJson) }} + {{ $enabledWorkerTypes := keys ((include "element-io.synapse.enabledWorkers" (dict "global" $ "context" .)) | fromJson) }} {{- range $workerType := $enabledWorkerTypes | sortAlpha }} - {{- $workersPaths := (include "element-io.synapse.process.workerPaths" (dict "workerType" $workerType "enabledWorkerTypes" $enabledWorkerTypes)) | fromJsonArray }} + {{- $workersPaths := (include "element-io.synapse.process.workerPaths" (dict "global" $ "context" (dict "workerType" $workerType "enabledWorkerTypes" $enabledWorkerTypes))) | fromJsonArray }} {{- if len $workersPaths }} # {{ $workerType }} {{- range $path := $workersPaths }} @@ -29,7 +33,7 @@ data: path_map_file_get: | # A map file that is used in haproxy config to map from matrix paths to the # named backend. The format is: path_regexp backend_name - {{ if dig "client-reader" "enabled" false .Values.workers }} + {{ if dig "client-reader" "enabled" false .workers }} ^/_matrix/client/(api/v1|r0|v3|unstable)/pushrules/ client-reader {{- end }} 429.http: | @@ -44,3 +48,5 @@ data:

429 Too Many Requests

No server is available to handle this request. +{{- end -}} +{{- end -}} diff --git a/charts/synapse/templates/haproxy_deployment.yaml b/charts/synapse/templates/haproxy_deployment.yaml index 9090b813..795ee9c6 100644 --- a/charts/synapse/templates/haproxy_deployment.yaml +++ b/charts/synapse/templates/haproxy_deployment.yaml @@ -1,8 +1,12 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd -{{- with .Values.haproxy }} +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} +{{- with .haproxy }} apiVersion: apps/v1 kind: Deployment metadata: @@ -11,7 +15,7 @@ metadata: {{- toYaml . | nindent 4 }} {{- end }} labels: - {{- include "element-io.synapse.haproxy.labels" $ | nindent 4 }} + {{- include "element-io.synapse.haproxy.labels" (dict "global" $ "context" .) | nindent 4 }} k8s.element.io/confighash: "{{ include (print $.Template.BasePath "/haproxy_configmap.yaml") $ | sha1sum }}" name: {{ $.Release.Name }}-synapse-haproxy namespace: {{ $.Release.Namespace }} @@ -28,7 +32,7 @@ spec: template: metadata: labels: - {{- include "element-io.synapse.haproxy.labels" $ | nindent 8 }} + {{- include "element-io.synapse.haproxy.labels" (dict "global" $ "context" .) | nindent 8 }} k8s.element.io/confighash: "{{ include (print $.Template.BasePath "/haproxy_configmap.yaml") $ | sha1sum }}" {{- with .annotations }} annotations: @@ -50,7 +54,7 @@ spec: topologyKey: kubernetes.io/hostname {{- end }} automountServiceAccountToken: false - serviceAccountName: {{ include "element-io.synapse.haproxy.serviceAccountName" $ }} + serviceAccountName: {{ include "element-io.synapse.haproxy.serviceAccountName" (dict "global" $ "context" .) }} {{- include "element-io.ess-library.pods.pullSecrets" (list $ .image) | nindent 6 }} {{- with .podSecurityContext }} securityContext: @@ -115,3 +119,5 @@ spec: defaultMode: 420 name: haproxy-config {{- end }} +{{- end -}} +{{- end -}} diff --git a/charts/synapse/templates/haproxy_service_monitor.yaml b/charts/synapse/templates/haproxy_service_monitor.yaml index d5ddf2fe..089a0ead 100644 --- a/charts/synapse/templates/haproxy_service_monitor.yaml +++ b/charts/synapse/templates/haproxy_service_monitor.yaml @@ -1,16 +1,20 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} {{- if .Capabilities.APIVersions.Has "monitoring.coreos.com/v1/ServiceMonitor" }} -{{- if .Values.haproxy.serviceMonitors.enabled }} +{{- if .haproxy.serviceMonitors.enabled }} apiVersion: monitoring.coreos.com/v1 kind: ServiceMonitor metadata: labels: - {{- include "element-io.synapse.haproxy.labels" $ | nindent 4 }} - name: {{ .Release.Name }}-synapse-haproxy - namespace: {{ .Release.Namespace }} + {{- include "element-io.synapse.haproxy.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ $.Release.Name }}-synapse-haproxy + namespace: {{ $.Release.Namespace }} spec: endpoints: - interval: 30s @@ -19,6 +23,9 @@ spec: matchLabels: app.kubernetes.io/part-of: matrix-stack app.kubernetes.io/component: matrix-server-ingress - app.kubernetes.io/instance: {{ .Release.Name }}-synapse-haproxy + app.kubernetes.io/instance: {{ $.Release.Name }}-synapse-haproxy {{- end }} {{- end }} +{{- end -}} +{{- end -}} + diff --git a/charts/synapse/templates/haproxy_serviceaccount.yaml b/charts/synapse/templates/haproxy_serviceaccount.yaml index d5efd698..30bc3b5c 100644 --- a/charts/synapse/templates/haproxy_serviceaccount.yaml +++ b/charts/synapse/templates/haproxy_serviceaccount.yaml @@ -1,18 +1,25 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd -{{- if .Values.haproxy.serviceAccount.create }} +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} +{{- if .haproxy.serviceAccount.create }} apiVersion: v1 kind: ServiceAccount metadata: - {{- with .Values.haproxy.serviceAccount.annotations }} + {{- with .haproxy.serviceAccount.annotations }} annotations: {{- toYaml . | nindent 4 }} {{- end }} labels: - {{- include "element-io.synapse.haproxy.labels" . | nindent 4 }} - name: {{ include "element-io.synapse.haproxy.serviceAccountName" . }} + {{- include "element-io.synapse.haproxy.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ include "element-io.synapse.haproxy.serviceAccountName" (dict "global" $ "context" .) }} namespace: {{ .Release.Namespace }} automountServiceAccountToken: false {{- end }} +{{- end -}} +{{- end -}} + diff --git a/charts/synapse/templates/redis_configmap.yaml b/charts/synapse/templates/redis_configmap.yaml index e7b8a5a8..daf3e088 100644 --- a/charts/synapse/templates/redis_configmap.yaml +++ b/charts/synapse/templates/redis_configmap.yaml @@ -1,13 +1,17 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd -{{- if (include "element-io.synapse.enabledWorkers" $) | fromJson }} +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} +{{- if (include "element-io.synapse.enabledWorkers" (dict "global" $ "context" .)) | fromJson }} apiVersion: v1 kind: ConfigMap metadata: labels: - {{- include "element-io.synapse.redis.labels" $ | nindent 4 }} + {{- include "element-io.synapse.redis.labels" (dict "global" $ "context" .) | nindent 4 }} name: {{ $.Release.Name }}-synapse-redis namespace: {{ $.Release.Namespace }} data: @@ -100,3 +104,5 @@ data: rdb-save-incremental-fsync yes jemalloc-bg-thread yes {{- end }} +{{- end -}} +{{- end -}} diff --git a/charts/synapse/templates/redis_deployment.yaml b/charts/synapse/templates/redis_deployment.yaml index 50ad30cb..defbdab4 100644 --- a/charts/synapse/templates/redis_deployment.yaml +++ b/charts/synapse/templates/redis_deployment.yaml @@ -1,9 +1,13 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd -{{- if (include "element-io.synapse.enabledWorkers" $) | fromJson }} -{{- with .Values.redis }} +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} +{{- if (include "element-io.synapse.enabledWorkers" (dict "global" $ "context" .)) | fromJson }} +{{- with .redis }} apiVersion: apps/v1 kind: Deployment metadata: @@ -12,7 +16,7 @@ metadata: {{- toYaml . | nindent 4 }} {{- end }} labels: - {{- include "element-io.synapse.redis.labels" $ | nindent 4 }} + {{- include "element-io.synapse.redis.labels" (dict "global" $ "context" .) | nindent 4 }} k8s.element.io/confighash: "{{ include (print $.Template.BasePath "/redis_configmap.yaml") $ | sha1sum }}" name: {{ $.Release.Name }}-synapse-redis namespace: {{ $.Release.Namespace }} @@ -29,7 +33,7 @@ spec: template: metadata: labels: - {{- include "element-io.synapse.redis.labels" $ | nindent 8 }} + {{- include "element-io.synapse.redis.labels" (dict "global" $ "context" .) | nindent 8 }} k8s.element.io/confighash: "{{ include (print $.Template.BasePath "/redis_configmap.yaml") $ | sha1sum }}" {{- with .annotations }} annotations: @@ -37,7 +41,7 @@ spec: {{- end }} spec: automountServiceAccountToken: false - serviceAccountName: {{ include "element-io.synapse.redis.serviceAccountName" $ }} + serviceAccountName: {{ include "element-io.synapse.redis.serviceAccountName" (dict "global" $ "context" .) }} {{- include "element-io.ess-library.pods.pullSecrets" (list $ .image) | nindent 6 }} {{- with .podSecurityContext }} securityContext: @@ -105,3 +109,5 @@ spec: name: data {{- end }} {{- end }} +{{- end -}} +{{- end -}} diff --git a/charts/synapse/templates/redis_service.yaml b/charts/synapse/templates/redis_service.yaml index 888ca187..12dc1470 100644 --- a/charts/synapse/templates/redis_service.yaml +++ b/charts/synapse/templates/redis_service.yaml @@ -1,19 +1,25 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd -{{- if (include "element-io.synapse.enabledWorkers" $) | fromJson }} +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} +{{- if (include "element-io.synapse.enabledWorkers" (dict "global" $ "context" .)) | fromJson }} apiVersion: v1 kind: Service metadata: labels: - {{- include "element-io.synapse.redis.labels" $ | nindent 4 }} - name: {{ .Release.Name }}-synapse-redis - namespace: {{ .Release.Namespace }} + {{- include "element-io.synapse.redis.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ $.Release.Name }}-synapse-redis + namespace: {{ $.Release.Namespace }} spec: ports: - port: 6379 targetPort: redis selector: - app.kubernetes.io/instance: "{{ .Release.Name }}-synapse-redis" + app.kubernetes.io/instance: "{{ $.Release.Name }}-synapse-redis" {{- end }} +{{- end -}} +{{- end -}} diff --git a/charts/synapse/templates/redis_serviceaccount.yaml b/charts/synapse/templates/redis_serviceaccount.yaml index 0a722784..38ad389f 100644 --- a/charts/synapse/templates/redis_serviceaccount.yaml +++ b/charts/synapse/templates/redis_serviceaccount.yaml @@ -1,20 +1,27 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd -{{- if (include "element-io.synapse.enabledWorkers" $) | fromJson }} -{{- if .Values.redis.serviceAccount.create }} +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} +{{- if (include "element-io.synapse.enabledWorkers" (dict "global" $ "context" .)) | fromJson }} +{{- if .redis.serviceAccount.create }} apiVersion: v1 kind: ServiceAccount metadata: - {{- with .Values.redis.serviceAccount.annotations }} + {{- with .redis.serviceAccount.annotations }} annotations: {{- toYaml . | nindent 4 }} {{- end }} labels: - {{- include "element-io.synapse.redis.labels" . | nindent 4 }} - name: {{ include "element-io.synapse.redis.serviceAccountName" . }} - namespace: {{ .Release.Namespace }} + {{- include "element-io.synapse.redis.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ include "element-io.synapse.redis.serviceAccountName" (dict "global" $ "context" .) }} + namespace: {{ $.Release.Namespace }} automountServiceAccountToken: false {{- end }} {{- end }} +{{- end -}} +{{- end -}} + diff --git a/charts/synapse/templates/synapse_configmap.yaml b/charts/synapse/templates/synapse_configmap.yaml index 02aaa013..dd970aa4 100644 --- a/charts/synapse/templates/synapse_configmap.yaml +++ b/charts/synapse/templates/synapse_configmap.yaml @@ -1,26 +1,30 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} apiVersion: v1 kind: ConfigMap metadata: labels: - {{- include "element-io.synapse.labels" $ | nindent 4 }} - name: {{ .Release.Name }}-synapse - namespace: {{ .Release.Namespace }} + {{- include "element-io.synapse.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ $.Release.Name }}-synapse + namespace: {{ $.Release.Namespace }} data: 01-homeserver-underrides.yaml: | - {{- include "element-io.synapse.config.shared-underrides" . | nindent 4 }} + {{- include "element-io.synapse.config.shared-underrides" (dict "global" $ "context" .) | nindent 4 }} {{- /*02 files are user provided in Helm values and end up in the Secret*/}} {{- /*03 files are user provided as secrets rather than directly in Helm*/}} 04-homeserver-overrides.yaml: | - {{- include "element-io.synapse.config.shared-overrides" . | nindent 4 }} + {{- include "element-io.synapse.config.shared-overrides" (dict "global" $ "context" .) | nindent 4 }} 05-main.yaml: | - {{- include "element-io.synapse.config.processSpecific" (dict "processType" "main" "Values" .Values) | nindent 4 }} -{{- range $workerType, $workerDetails := (include "element-io.synapse.enabledWorkers" $) | fromJson }} + {{- include "element-io.synapse.config.processSpecific" (dict "global" $ "context" (dict "processType" "main" "Values" .)) | nindent 4 }} +{{- range $workerType, $workerDetails := (include "element-io.synapse.enabledWorkers" (dict "global" $ "context" .)) | fromJson }} 05-{{ $workerType }}.yaml: | - {{- include "element-io.synapse.config.processSpecific" (dict "processType" $workerType "Values" $.Values) | nindent 4 }} + {{- include "element-io.synapse.config.processSpecific" (dict "global" $ "context" (dict "processType" $workerType "Values" $.synapse.Values)) | nindent 4 }} {{- end }} log_config.yaml: | # Copyright 2024 New Vector Ltd @@ -43,16 +47,18 @@ data: nuked if an override is set and then if the root level is increased to debug, the access tokens will be logged. Putting here means it is an explicit customer choice to override it. */}} - {{- range $logger, $level := merge dict .Values.logging.levelOverrides (dict "synapse.storage.SQL" "INFO") }} + {{- range $logger, $level := merge dict .logging.levelOverrides (dict "synapse.storage.SQL" "INFO") }} {{ $logger }}: level: "{{ $level }}" {{- end }} root: - level: "{{ .Values.logging.rootLevel }}" + level: "{{ .logging.rootLevel }}" handlers: - console disable_existing_loggers: false render_config_with_secrets.py: | {{- ($.Files.Get "configs/synapse/render_config_with_secrets.py") | nindent 4 }} +{{- end -}} +{{- end -}} diff --git a/charts/synapse/templates/synapse_http_service.yaml b/charts/synapse/templates/synapse_http_service.yaml index 63568c98..078b3f79 100644 --- a/charts/synapse/templates/synapse_http_service.yaml +++ b/charts/synapse/templates/synapse_http_service.yaml @@ -1,16 +1,20 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} apiVersion: v1 kind: Service metadata: labels: - {{- include "element-io.synapse.haproxy.labels" $ | nindent 4 }} - name: {{ .Release.Name }}-synapse-haproxy - namespace: {{ .Release.Namespace }} + {{- include "element-io.synapse.haproxy.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ $.Release.Name }}-synapse-haproxy + namespace: {{ $.Release.Namespace }} spec: - type: {{ .Values.ingress.service.type }} + type: {{ .ingress.service.type }} ports: - name: haproxy-http port: 8008 @@ -22,4 +26,6 @@ spec: port: 8405 targetPort: haproxy-metrics selector: - app.kubernetes.io/instance: "{{ .Release.Name }}-synapse-haproxy" + app.kubernetes.io/instance: "{{ $.Release.Name }}-synapse-haproxy" +{{- end -}} +{{- end -}} diff --git a/charts/synapse/templates/synapse_ingress.yaml b/charts/synapse/templates/synapse_ingress.yaml index 5e756340..1fe701ad 100644 --- a/charts/synapse/templates/synapse_ingress.yaml +++ b/charts/synapse/templates/synapse_ingress.yaml @@ -1,33 +1,37 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} apiVersion: networking.k8s.io/v1 kind: Ingress metadata: -{{- with .Values.ingress.annotations }} +{{- with .ingress.annotations }} annotations: {{- toYaml . | nindent 4 }} {{- end }} labels: - {{- include "element-io.synapse.haproxy.labels" $ | nindent 4 }} - name: {{ .Release.Name }}-synapse - namespace: {{ .Release.Namespace }} + {{- include "element-io.synapse.haproxy.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ $.Release.Name }}-synapse + namespace: {{ $.Release.Namespace }} spec: -{{- if .Values.ingress.tlsSecret }} +{{- if .ingress.tlsSecret }} tls: - hosts: - - {{ .Values.ingress.host | quote }} - secretName: {{ .Values.ingress.tlsSecret | quote }} + - {{ .ingress.host | quote }} + secretName: {{ .ingress.tlsSecret | quote }} {{- end }} -{{- with .Values.ingress.className }} +{{- with .ingress.className }} ingressClassName: {{ . | quote }} {{- end }} rules: - - host: {{ .Values.ingress.host | quote }} + - host: {{ .ingress.host | quote }} http: paths: -{{- range .Values.ingress.additionalPaths -}} +{{- range .ingress.additionalPaths -}} {{- if eq .availability "only_externally" }} - path: {{ .path }} pathType: Prefix @@ -51,7 +55,7 @@ spec: defined additional paths. If so, let the other service handle it and don't add it here. */}} {{- $_pathAlreadyDefined := false }} -{{- range $.Values.ingress.additionalPaths -}} +{{- range $.ingress.additionalPaths -}} {{- if has .availability (list "only_externally" "blocked") }} {{- if hasPrefix .path $synapsePath }} {{- $_pathAlreadyDefined = true }} @@ -70,3 +74,6 @@ spec: name: haproxy-http {{- end }} {{- end }} +{{- end -}} +{{- end -}} + diff --git a/charts/synapse/templates/synapse_persistentvolumeclaim.yaml b/charts/synapse/templates/synapse_persistentvolumeclaim.yaml index 59663f4a..918d212b 100644 --- a/charts/synapse/templates/synapse_persistentvolumeclaim.yaml +++ b/charts/synapse/templates/synapse_persistentvolumeclaim.yaml @@ -1,22 +1,28 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd -{{- if not .Values.media.storage.existingClaim }} +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} +{{- if not .media.storage.existingClaim }} apiVersion: v1 kind: PersistentVolumeClaim metadata: labels: - {{- include "element-io.synapse.labels" $ | nindent 4 }} - name: {{ .Release.Name }}-synapse-media - namespace: {{ .Release.Namespace }} + {{- include "element-io.synapse.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ $.Release.Name }}-synapse-media + namespace: {{ $.Release.Namespace }} spec: -{{- with .Values.media.storage.storageClassName }} +{{- with .media.storage.storageClassName }} storageClassName: {{ . }} {{- end }} accessModes: - ReadWriteOnce resources: requests: - storage: {{ .Values.media.storage.size }} + storage: {{ .media.storage.size }} {{- end }} +{{- end -}} +{{- end -}} diff --git a/charts/synapse/templates/synapse_secret.yaml b/charts/synapse/templates/synapse_secret.yaml index de14f73f..93da3174 100644 --- a/charts/synapse/templates/synapse_secret.yaml +++ b/charts/synapse/templates/synapse_secret.yaml @@ -1,27 +1,33 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} apiVersion: v1 kind: Secret metadata: labels: - {{- include "element-io.synapse.labels" $ | nindent 4 }} - name: {{ .Release.Name }}-synapse - namespace: {{ .Release.Namespace }} + {{- include "element-io.synapse.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ $.Release.Name }}-synapse + namespace: {{ $.Release.Namespace }} data: -{{- with .Values.additional.config }} +{{- with .additional.config }} 02-homeserver-helm-user-provided.yaml: {{ . | b64enc }} {{- end }} -{{- with .Values.macaroon.value }} +{{- with .macaroon.value }} MACAROON: {{ . | b64enc }} {{- end }} -{{- with .Values.postgres.password.value }} +{{- with .postgres.password.value }} POSTGRES: {{ . | b64enc }} {{- end }} -{{- with .Values.registrationSharedSecret.value }} +{{- with .registrationSharedSecret.value }} REGISTRATION_SHARED_SECRET: {{ . | b64enc }} {{- end }} -{{- with .Values.signingKey.value }} +{{- with .signingKey.value }} SIGNING_KEY: {{ .| b64enc }} {{- end }} +{{- end -}} +{{- end -}} diff --git a/charts/synapse/templates/synapse_service.yaml b/charts/synapse/templates/synapse_service.yaml index 1289d512..2284bcba 100644 --- a/charts/synapse/templates/synapse_service.yaml +++ b/charts/synapse/templates/synapse_service.yaml @@ -1,25 +1,29 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd -{{- range $processType := prepend (keys ((include "element-io.synapse.enabledWorkers" $) | fromJson)) "main" }} +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} +{{- range $processType := prepend (keys ((include "element-io.synapse.enabledWorkers" (dict "global" $ "context" .)) | fromJson)) "main" }} {{- $perProcessRoot := merge (dict "ProcessType" $processType) $ }} apiVersion: v1 kind: Service metadata: labels: - {{- include "element-io.synapse.process.labels" $perProcessRoot | nindent 4 }} + {{- include "element-io.synapse.process.labels" (dict "global" $ "context" $perProcessRoot) | nindent 4 }} name: {{ $.Release.Name }}-synapse-{{ $processType }} namespace: {{ $.Release.Namespace }} spec: clusterIP: None ports: -{{- if (include "element-io.synapse.process.hasHttp" .) }} +{{- if (include "element-io.synapse.process.hasHttp" (dict "global" $ "context" .)) }} - name: synapse-http port: 8008 targetPort: synapse-http {{- end }} -{{- if (include "element-io.synapse.process.hasReplication" .) }} +{{- if (include "element-io.synapse.process.hasReplication" (dict "global" $ "context" .)) }} - name: synapse-repl port: 9093 targetPort: synapse-repl @@ -34,3 +38,5 @@ spec: app.kubernetes.io/instance: {{ $.Release.Name }}-synapse-{{ $processType }} --- {{- end }} +{{- end -}} +{{- end -}} diff --git a/charts/synapse/templates/synapse_service_monitor.yaml b/charts/synapse/templates/synapse_service_monitor.yaml index 6c88cab6..f95c6545 100644 --- a/charts/synapse/templates/synapse_service_monitor.yaml +++ b/charts/synapse/templates/synapse_service_monitor.yaml @@ -1,16 +1,20 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} {{- if .Capabilities.APIVersions.Has "monitoring.coreos.com/v1/ServiceMonitor" }} -{{- if .Values.serviceMonitors.enabled }} +{{- if .serviceMonitors.enabled }} apiVersion: monitoring.coreos.com/v1 kind: ServiceMonitor metadata: labels: - {{- include "element-io.synapse.labels" $ | nindent 4 }} - name: {{ .Release.Name }}-synapse - namespace: {{ .Release.Namespace }} + {{- include "element-io.synapse.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ $.Release.Name }}-synapse + namespace: {{ $.Release.Namespace }} spec: endpoints: - interval: 30s @@ -18,11 +22,13 @@ spec: relabelings: - targetLabel: instance action: replace - replacement: {{ .Values.ingress.host }} + replacement: {{ .ingress.host }} selector: matchLabels: app.kubernetes.io/part-of: matrix-stack app.kubernetes.io/component: matrix-server - k8s.element.io/synapse-instance: {{ .Release.Name }}-synapse + k8s.element.io/synapse-instance: {{ $.Release.Name }}-synapse {{- end }} {{- end }} +{{- end -}} +{{- end -}} diff --git a/charts/synapse/templates/synapse_serviceaccount.yaml b/charts/synapse/templates/synapse_serviceaccount.yaml index 6f140fb9..81da93f8 100644 --- a/charts/synapse/templates/synapse_serviceaccount.yaml +++ b/charts/synapse/templates/synapse_serviceaccount.yaml @@ -1,18 +1,25 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd -{{- if .Values.serviceAccount.create }} +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} +{{- if .serviceAccount.create }} apiVersion: v1 kind: ServiceAccount metadata: - {{- with .Values.serviceAccount.annotations }} + {{- with .serviceAccount.annotations }} annotations: {{- toYaml . | nindent 4 }} {{- end }} labels: - {{- include "element-io.synapse.labels" . | nindent 4 }} - name: {{ include "element-io.synapse.serviceAccountName" . }} - namespace: {{ .Release.Namespace }} + {{- include "element-io.synapse.labels" (dict "global" $ "context" .) | nindent 4 }} + name: {{ include "element-io.synapse.serviceAccountName" (dict "global" $ "context" .) }} + namespace: {{ $.Release.Namespace }} automountServiceAccountToken: false {{- end }} +{{- end -}} +{{- end -}} + diff --git a/charts/synapse/templates/synapse_statefulset.yaml b/charts/synapse/templates/synapse_statefulset.yaml index c378f697..bcc889e7 100644 --- a/charts/synapse/templates/synapse_statefulset.yaml +++ b/charts/synapse/templates/synapse_statefulset.yaml @@ -1,30 +1,34 @@ -# Copyright 2024 New Vector Ltd -# -# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +{{- /* +Copyright 2024 New Vector Ltd -{{- $enabledWorkers := (include "element-io.synapse.enabledWorkers" $) | fromJson }} +SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +*/ -}} + +{{- with .Values.synapse -}} +{{- if .enabled -}} +{{- $enabledWorkers := (include "element-io.synapse.enabledWorkers" (dict "global" $ "context" .)) | fromJson }} {{- range $processType, $unmergedProcessDetails := merge $enabledWorkers (dict "main" dict) }} {{- $perProcessRoot := merge (dict "ProcessType" $processType) $ }} {{- with dict "Values" (merge dict ($unmergedProcessDetails | deepCopy) ($.Values | deepCopy)) }} apiVersion: apps/v1 kind: StatefulSet metadata: -{{- with .Values.annotations }} +{{- with .annotations }} annotations: {{- toYaml . | nindent 4 }} {{- end }} labels: - {{- include "element-io.synapse.process.labels" $perProcessRoot | nindent 4 }} + {{- include "element-io.synapse.process.labels" (dict "global" $ "context" $perProcessRoot) | nindent 4 }} k8s.element.io/confighash: "{{ include (print $.Template.BasePath "/synapse_secret.yaml") $ | sha1sum }}" k8s.element.io/logconfighash: "{{ include (print $.Template.BasePath "/synapse_configmap.yaml") $ | sha1sum }}" -{{- range $index, $appservice := .Values.appservices }} +{{- range $index, $appservice := .appservices }} k8s.element.io/as-registration-{{ $index }}-hash: "{{ (lookup "v1" "ConfigMap" $.Release.Namespace $appservice.registrationFileConfigMap) | toJson | sha1sum }}" {{- end }} name: {{ $.Release.Name }}-synapse-{{ $processType }} namespace: {{ $.Release.Namespace }} spec: serviceName: {{ $.Release.Name }}-synapse-{{ $processType }} - replicas: {{ .Values.instances | default 1 }} + replicas: {{ .instances | default 1 }} selector: matchLabels: app.kubernetes.io/instance: {{ $.Release.Name }}-synapse-{{ $processType }} @@ -35,34 +39,34 @@ spec: template: metadata: labels: - {{- include "element-io.synapse.process.labels" $perProcessRoot | nindent 8 }} + {{- include "element-io.synapse.process.labels" (dict "global" $ "context" $perProcessRoot) | nindent 8 }} k8s.element.io/confighash: "{{ include (print $.Template.BasePath "/synapse_secret.yaml") $ | sha1sum }}" k8s.element.io/logconfighash: "{{ include (print $.Template.BasePath "/synapse_configmap.yaml") $ | sha1sum }}" -{{- range $index, $appservice := .Values.appservices }} +{{- range $index, $appservice := .appservices }} k8s.element.io/as-registration-{{ $index }}-hash: "{{ (lookup "v1" "ConfigMap" $.Release.Namespace $appservice.registrationFileConfigMap) | toJson | sha1sum }}" {{- end }} -{{- with .Values.annotations }} +{{- with .annotations }} annotations: {{- toYaml . | nindent 8 }} {{- end }} spec: automountServiceAccountToken: false - serviceAccountName: {{ include "element-io.synapse.serviceAccountName" $ }} -{{- include "element-io.ess-library.pods.pullSecrets" (list $ .Values.image) | nindent 6 }} -{{- with .Values.podSecurityContext }} + serviceAccountName: {{ include "element-io.synapse.serviceAccountName" (dict "global" $ "context" .) }} +{{- include "element-io.ess-library.pods.pullSecrets" (list $ .image) | nindent 6 }} +{{- with .podSecurityContext }} securityContext: {{- toYaml . | nindent 8 }} {{- end }} -{{- with .Values.nodeSelector }} +{{- with .nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} {{- end }} -{{- with .Values.tolerations }} +{{- with .tolerations }} tolerations: {{- toYaml . | nindent 8 }} {{- end }} -{{- with .Values.hostAliases }} +{{- with .hostAliases }} hostAliases: {{- toYaml . | nindent 8 }} {{- end }} @@ -75,7 +79,7 @@ We have an init container to render & merge the config for several reasons: */}} initContainers: - name: render-config -{{- with .Values.image -}} +{{- with .image -}} {{- if .digest }} image: "{{ .registry }}/{{ .repository }}@{{ .digest }}" imagePullPolicy: {{ .pullPolicy | default "IfNotPresent" }} @@ -84,7 +88,7 @@ We have an init container to render & merge the config for several reasons: imagePullPolicy: {{ .pullPolicy | default "Always" }} {{- end }} {{- end }} -{{- with .Values.containersSecurityContext }} +{{- with .containersSecurityContext }} securityContext: {{- toYaml . | nindent 10 }} {{- end }} @@ -99,9 +103,9 @@ We have an init container to render & merge the config for several reasons: These could be done as env vars with valueFrom.secretKeyRef, but that triggers CKV_K8S_35. If we wanted to allow for replacement of values in the user-provided config with external Secrets we could extend this init-container to allow extraEnv with valueFrom.secretKeyRef. */}} - export SYNAPSE_MACAROON=$(cat /secrets/{{ .Values.macaroon.secret | default (printf "%s-synapse" $.Release.Name) }}/{{ .Values.macaroon.secretKey | default "MACAROON" }}); - export SYNAPSE_POSTGRES_PASSWORD=$(cat /secrets/{{ .Values.postgres.password.secret | default (printf "%s-synapse" $.Release.Name) }}/{{ .Values.postgres.password.secretKey | default "POSTGRES_PASSWORD" }}); - export SYNAPSE_REGISTRATION_SHARED_SECRET=$(cat /secrets/{{ .Values.registrationSharedSecret.secret | default (printf "%s-synapse" $.Release.Name) }}/{{ .Values.registrationSharedSecret.secretKey | default "REGISTRATION_SHARED_SECRET" }}); + export SYNAPSE_MACAROON=$(cat /secrets/{{ .macaroon.secret | default (printf "%s-synapse" $.Release.Name) }}/{{ .macaroon.secretKey | default "MACAROON" }}); + export SYNAPSE_POSTGRES_PASSWORD=$(cat /secrets/{{ .postgres.password.secret | default (printf "%s-synapse" $.Release.Name) }}/{{ .postgres.password.secretKey | default "POSTGRES_PASSWORD" }}); + export SYNAPSE_REGISTRATION_SHARED_SECRET=$(cat /secrets/{{ .registrationSharedSecret.secret | default (printf "%s-synapse" $.Release.Name) }}/{{ .registrationSharedSecret.secretKey | default "REGISTRATION_SHARED_SECRET" }}); set -x; export APPLICATION_NAME=$(hostname -s | sed 's/.*-synapse-//g'); @@ -109,16 +113,16 @@ We have an init container to render & merge the config for several reasons: python3 /config-templates/render_config_with_secrets.py \ /config-templates/01-homeserver-underrides.yaml \ - {{- if .Values.additional.config }} + {{- if .additional.config }} /secrets/{{ $.Release.Name }}-synapse/02-homeserver-helm-user-provided.yaml \ {{- end }} - {{- if .Values.additional.configSecret }} - /secrets/{{ .Values.additional.configSecret }}/{{ .Values.additional.configSecretKey }} \ + {{- if .additional.configSecret }} + /secrets/{{ .additional.configSecret }}/{{ .additional.configSecretKey }} \ {{- end }} /config-templates/04-homeserver-overrides.yaml \ /config-templates/05-{{ $processType }}.yaml \ > /conf/homeserver.yaml; -{{- with .Values.resources }} +{{- with .resources }} resources: {{- toYaml . | nindent 10 }} {{- end }} @@ -126,7 +130,7 @@ We have an init container to render & merge the config for several reasons: - mountPath: /config-templates name: plain-config readOnly: true -{{- range $secret := include "element-io.synapse.configSecrets" $ | fromJsonArray }} +{{- range $secret := include "element-io.synapse.configSecrets" (dict "global" $ "context" .) | fromJsonArray }} - mountPath: /secrets/{{ $secret }} name: "secret-{{ $secret }}" readOnly: true @@ -136,7 +140,7 @@ We have an init container to render & merge the config for several reasons: readOnly: false containers: - name: synapse -{{- with .Values.image -}} +{{- with .image -}} {{- if .digest }} image: "{{ .registry }}/{{ .repository }}@{{ .digest }}" imagePullPolicy: {{ .pullPolicy | default "IfNotPresent" }} @@ -145,7 +149,7 @@ We have an init container to render & merge the config for several reasons: imagePullPolicy: {{ .pullPolicy | default "Always" }} {{- end }} {{- end }} -{{- with .Values.containersSecurityContext }} +{{- with .containersSecurityContext }} securityContext: {{- toYaml . | nindent 10 }} {{- end }} @@ -155,18 +159,18 @@ We have an init container to render & merge the config for several reasons: - > ls -lR /secrets; [ -e "/usr/lib/`uname -m`-linux-gnu/libjemalloc.so.2" ] && export LD_PRELOAD="/usr/lib/`uname -m`-linux-gnu/libjemalloc.so.2"; - python3 -m {{ include "element-io.synapse.process.app" $processType }} -c /conf/homeserver.yaml -{{- with .Values.extraEnv }} + python3 -m {{ include "element-io.synapse.process.app" (dict "global" $ "context" $processType) }} -c /conf/homeserver.yaml +{{- with .extraEnv }} env: {{- toYaml . | nindent 10 }} {{- end }} ports: -{{- if (include "element-io.synapse.process.hasHttp" $processType) }} +{{- if (include "element-io.synapse.process.hasHttp" (dict "global" $ "context" $processType)) }} - containerPort: 8008 name: synapse-http protocol: TCP {{- end }} -{{- if (include "element-io.synapse.process.hasReplication" $processType) }} +{{- if (include "element-io.synapse.process.hasReplication" (dict "global" $ "context" $processType)) }} - containerPort: 9093 name: synapse-repl protocol: TCP @@ -191,7 +195,7 @@ We have an init container to render & merge the config for several reasons: timeoutSeconds: 2 {{- /* For Synapse processes where there can only be 1 instance we're more generous with the threshold. This is because people can't scale the process up and so the impact of a restart is greater. */}} - failureThreshold: {{ ternary 8 3 (eq "isSingle" (include "element-io.synapse.process.isSingle" $processType)) }} + failureThreshold: {{ ternary 8 3 (eq "isSingle" (include "element-io.synapse.process.isSingle" (dict "global" $ "context" $processType))) }} readinessProbe: httpGet: path: /health @@ -199,18 +203,18 @@ We have an init container to render & merge the config for several reasons: periodSeconds: 2 timeoutSeconds: 2 successThreshold: 2 - failureThreshold: {{ ternary 8 3 (eq "isSingle" (include "element-io.synapse.process.isSingle" $processType)) }} -{{- with .Values.resources }} + failureThreshold: {{ ternary 8 3 (eq "isSingle" (include "element-io.synapse.process.isSingle" (dict "global" $ "context" $processType))) }} +{{- with .resources }} resources: {{- toYaml . | nindent 10 }} {{- end }} volumeMounts: -{{- range $secret := include "element-io.synapse.configSecrets" $ | fromJsonArray }} +{{- range $secret := include "element-io.synapse.configSecrets" (dict "global" $ "context" .) | fromJsonArray }} - mountPath: /secrets/{{ $secret }} name: "secret-{{ $secret }}" readOnly: true {{- end }} -{{- range $appservice := .Values.appservices }} +{{- range $appservice := .appservices }} - name: {{ $appservice.registrationFileConfigMap }} mountPath: /as/{{ $appservice.registrationFileConfigMap }}/registration.yaml readOnly: true @@ -230,7 +234,7 @@ We have an init container to render & merge the config for several reasons: defaultMode: 420 name: "{{ $.Release.Name }}-synapse" name: plain-config -{{- range $secret := include "element-io.synapse.configSecrets" $ | fromJsonArray }} +{{- range $secret := include "element-io.synapse.configSecrets" (dict "global" $ "context" .) | fromJsonArray }} - secret: secretName: {{ $secret }} name: secret-{{ $secret }} @@ -238,7 +242,7 @@ We have an init container to render & merge the config for several reasons: - emptyDir: medium: Memory name: "rendered-config" -{{- range $appservice := .Values.appservices }} +{{- range $appservice := .appservices }} - configMap: defaultMode: 420 name: "{{ $appservice.registrationFileConfigMap }}" @@ -246,7 +250,7 @@ We have an init container to render & merge the config for several reasons: {{- end }} {{- if (include "element-io.synapse.process.responsibleForMedia" (dict "processType" $processType "enabledWorkerTypes" (keys $enabledWorkers))) }} - persistentVolumeClaim: - claimName: {{ include "element-io.synapse.pvcName" $ }} + claimName: {{ include "element-io.synapse.pvcName" (dict "global" $ "context" $processType) }} name: "media" {{- else }} - emptyDir: @@ -259,3 +263,6 @@ We have an init container to render & merge the config for several reasons: --- {{- end }} {{- end }} +{{- end -}} +{{- end -}} + diff --git a/charts/synapse/values.schema.json b/charts/synapse/values.schema.json index 8b936342..3e59fbbe 100644 --- a/charts/synapse/values.schema.json +++ b/charts/synapse/values.schema.json @@ -3,44 +3,174 @@ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { - "enabled": { - "type": "boolean" - }, - "postgres": { + "global": { "type": "object", - "required": [ - "host", - "user", - "database", - "password" - ], + "additionalProperties": true, "properties": { - "host": { + "ess": { + "type": "object", + "properties": { + "server_name": { + "type": "string" + }, + "labels": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "imagePullSecrets": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string" + } + }, + "additionalProperties": false + } + } + }, + "additionalProperties": false + } + } + }, + "ess": { + "type": "object", + "additionalProperties": true, + "properties": { + "serverName": { "type": "string" }, - "port": { - "type": "integer", - "minimum": 0, - "maximum": 65535 + "labels": { + "type": "object", + "additionalProperties": { + "type": "string" + } }, - "user": { - "type": "string" + "imagePullSecrets": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string" + } + }, + "additionalProperties": false + } + } + } + }, + "ess-library": { + "type": "object", + "additionalProperties": true + }, + "synapse": { + "type": "object", + "properties": { + "enabled": { + "type": "boolean" }, - "database": { - "type": "string" + "postgres": { + "type": "object", + "required": [ + "host", + "user", + "database", + "password" + ], + "properties": { + "host": { + "type": "string" + }, + "port": { + "type": "integer", + "minimum": 0, + "maximum": 65535 + }, + "user": { + "type": "string" + }, + "database": { + "type": "string" + }, + "sslMode": { + "type": "string", + "enum": [ + "disable", + "allow", + "prefer", + "require", + "verify-ca", + "verify-full" + ] + }, + "password": { + "type": "object", + "oneOf": [ + { + "required": [ + "value" + ], + "not": { + "required": [ + "secret", + "secretKey" + ] + } + }, + { + "required": [ + "secret", + "secretKey" + ], + "not": { + "required": [ + "value" + ] + } + } + ], + "properties": { + "value": { + "type": "string" + }, + "secret": { + "type": "string" + }, + "secretKey": { + "type": "string" + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false }, - "sslMode": { - "type": "string", - "enum": [ - "disable", - "allow", - "prefer", - "require", - "verify-ca", - "verify-full" - ] + "media": { + "type": "object", + "properties": { + "storage": { + "type": "object", + "properties": { + "existingClaim": { + "type": "string" + }, + "size": { + "type": "string" + }, + "storageClass": { + "type": "string" + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false }, - "password": { + "macaroon": { "type": "object", "oneOf": [ { @@ -78,355 +208,295 @@ } }, "additionalProperties": false - } - }, - "additionalProperties": false - }, - "media": { - "type": "object", - "properties": { - "storage": { + }, + "registrationSharedSecret": { "type": "object", + "oneOf": [ + { + "required": [ + "value" + ], + "not": { + "required": [ + "secret", + "secretKey" + ] + } + }, + { + "required": [ + "secret", + "secretKey" + ], + "not": { + "required": [ + "value" + ] + } + } + ], "properties": { - "existingClaim": { + "value": { "type": "string" }, - "size": { + "secret": { "type": "string" }, - "storageClass": { + "secretKey": { "type": "string" } }, "additionalProperties": false - } - }, - "additionalProperties": false - }, - "macaroon": { - "type": "object", - "oneOf": [ - { - "required": [ - "value" - ], - "not": { - "required": [ - "secret", - "secretKey" - ] - } }, - { - "required": [ - "secret", - "secretKey" - ], - "not": { - "required": [ - "value" - ] - } - } - ], - "properties": { - "value": { - "type": "string" - }, - "secret": { - "type": "string" - }, - "secretKey": { - "type": "string" - } - }, - "additionalProperties": false - }, - "registrationSharedSecret": { - "type": "object", - "oneOf": [ - { - "required": [ - "value" - ], - "not": { - "required": [ - "secret", - "secretKey" - ] - } - }, - { - "required": [ - "secret", - "secretKey" - ], - "not": { - "required": [ - "value" - ] - } - } - ], - "properties": { - "value": { - "type": "string" - }, - "secret": { - "type": "string" - }, - "secretKey": { - "type": "string" - } - }, - "additionalProperties": false - }, - "signingKey": { - "type": "object", - "oneOf": [ - { - "required": [ - "value" - ], - "not": { - "required": [ - "secret", - "secretKey" - ] - } - }, - { - "required": [ - "secret", - "secretKey" - ], - "not": { - "required": [ - "value" - ] - } - } - ], - "properties": { - "value": { - "type": "string" - }, - "secret": { - "type": "string" - }, - "secretKey": { - "type": "string" - } - }, - "additionalProperties": false - }, - "additional": { - "type": "object", - "anyOf": [ - { - "required": [] - }, - { - "required": [ - "config" - ] - }, - { - "required": [ - "configSecret", - "configSecretKey" - ] - } - ], - "properties": { - "config": { - "type": "string" - }, - "configSecret": { - "type": "string" - }, - "configSecretKey": { - "type": "string" - } - }, - "additionalProperties": false - }, - "appservices": { - "type": "array", - "items": { - "type": "object", - "properties": { - "registrationFileConfigMap": { - "type": "string" - } - }, - "additionalProperties": false - } - }, - "logging": { - "type": "object", - "properties": { - "rootLevel": { - "type": "string", - "enum": [ - "CRITICAL", - "ERROR", - "WARNING", - "INFO", - "DEBUG" - ] - }, - "levelOverrides": { - "type": "object", - "additionalProperties": { - "type": "string", - "enum": [ - "CRITICAL", - "ERROR", - "WARNING", - "INFO", - "DEBUG" - ] - } - } - }, - "additionalProperties": false - }, - "global": { - "type": "object", - "additionalProperties": true, - "properties": { - "ess": { + "signingKey": { "type": "object", + "oneOf": [ + { + "required": [ + "value" + ], + "not": { + "required": [ + "secret", + "secretKey" + ] + } + }, + { + "required": [ + "secret", + "secretKey" + ], + "not": { + "required": [ + "value" + ] + } + } + ], "properties": { - "server_name": { + "value": { "type": "string" }, - "labels": { + "secret": { + "type": "string" + }, + "secretKey": { + "type": "string" + } + }, + "additionalProperties": false + }, + "additional": { + "type": "object", + "anyOf": [ + { + "required": [] + }, + { + "required": [ + "config" + ] + }, + { + "required": [ + "configSecret", + "configSecretKey" + ] + } + ], + "properties": { + "config": { + "type": "string" + }, + "configSecret": { + "type": "string" + }, + "configSecretKey": { + "type": "string" + } + }, + "additionalProperties": false + }, + "appservices": { + "type": "array", + "items": { + "type": "object", + "properties": { + "registrationFileConfigMap": { + "type": "string" + } + }, + "additionalProperties": false + } + }, + "logging": { + "type": "object", + "properties": { + "rootLevel": { + "type": "string", + "enum": [ + "CRITICAL", + "ERROR", + "WARNING", + "INFO", + "DEBUG" + ] + }, + "levelOverrides": { + "type": "object", + "additionalProperties": { + "type": "string", + "enum": [ + "CRITICAL", + "ERROR", + "WARNING", + "INFO", + "DEBUG" + ] + } + } + }, + "additionalProperties": false + }, + "global": { + "type": "object", + "additionalProperties": true, + "properties": { + "ess": { + "type": "object", + "properties": { + "server_name": { + "type": "string" + }, + "labels": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "imagePullSecrets": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string" + } + }, + "additionalProperties": false + } + } + }, + "additionalProperties": false + } + } + }, + "ess-library": { + "type": "object", + "additionalProperties": true + }, + "ingress": { + "type": "object", + "required": [ + "host" + ], + "properties": { + "annotations": { "type": "object", "additionalProperties": { "type": "string" } }, - "imagePullSecrets": { + "host": { + "type": "string" + }, + "className": { + "type": "string" + }, + "tlsSecret": { + "type": "string" + }, + "service": { + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "type": "string", + "enum": [ + "ClusterIP", + "NodePort", + "LoadBalancer" + ] + } + }, + "additionalProperties": false + }, + "additionalPaths": { "type": "array", "items": { - "type": "object", - "properties": { - "name": { - "type": "string" - } - }, - "additionalProperties": false - } - } - }, - "additionalProperties": false - } - } - }, - "ess-library": { - "type": "object", - "additionalProperties": true - }, - "ingress": { - "type": "object", - "required": [ - "host" - ], - "properties": { - "annotations": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "host": { - "type": "string" - }, - "className": { - "type": "string" - }, - "tlsSecret": { - "type": "string" - }, - "service": { - "type": "object", - "required": [ - "type" - ], - "properties": { - "type": { - "type": "string", - "enum": [ - "ClusterIP", - "NodePort", - "LoadBalancer" - ] - } - }, - "additionalProperties": false - }, - "additionalPaths": { - "type": "array", - "items": { - "type": "object", - "required": [ - "path", - "availability" - ], - "properties": { - "path": { - "type": "string" - }, - "availability": { - "type": "string", - "enum": [ - "internally_and_externally", - "only_externally", - "blocked" - ] - }, - "service": { "type": "object", "required": [ - "name", - "port" + "path", + "availability" ], "properties": { - "name": { + "path": { "type": "string" }, - "port": { + "availability": { + "type": "string", + "enum": [ + "internally_and_externally", + "only_externally", + "blocked" + ] + }, + "service": { "type": "object", - "oneOf": [ - { - "required": [ - "name" - ], - "not": { - "required": [ - "number" - ] - } - }, - { - "required": [ - "number" - ], - "not": { - "required": [ - "name" - ] - } - } + "required": [ + "name", + "port" ], "properties": { "name": { "type": "string" }, - "number": { - "type": "integer" + "port": { + "type": "object", + "oneOf": [ + { + "required": [ + "name" + ], + "not": { + "required": [ + "number" + ] + } + }, + { + "required": [ + "number" + ], + "not": { + "required": [ + "name" + ] + } + } + ], + "properties": { + "name": { + "type": "string" + }, + "number": { + "type": "integer" + } + }, + "additionalProperties": false } }, "additionalProperties": false @@ -434,1162 +504,10 @@ }, "additionalProperties": false } - }, - "additionalProperties": false - } - } - }, - "additionalProperties": false - }, - "image": { - "type": "object", - "required": [ - "repository" - ], - "properties": { - "registry": { - "type": "string" - }, - "repository": { - "type": "string" - }, - "tag": { - "type": "string" - }, - "digest": { - "type": "string" - }, - "pullPolicy": { - "type": "string", - "enum": [ - "Always", - "IfNotPresent", - "Never" - ] - }, - "pullSecrets": { - "type": "array", - "items": { - "type": "object", - "properties": { - "name": { - "type": "string" - } - }, - "additionalProperties": false - } - } - }, - "additionalProperties": false - }, - "labels": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "annotations": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "containersSecurityContext": { - "properties": { - "allowPrivilegeEscalation": { - "type": "boolean" - }, - "capabilities": { - "properties": { - "add": { - "items": { - "type": "string" - }, - "type": "array" - }, - "drop": { - "items": { - "type": "string" - }, - "type": "array" } }, - "type": "object", "additionalProperties": false }, - "readOnlyRootFilesystem": { - "type": "boolean" - }, - "seccompProfile": { - "properties": { - "localhostProfile": { - "type": "string" - }, - "type": { - "enum": [ - "RuntimeDefault", - "Unconfined", - "Localhost" - ], - "type": "string" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "extraEnv": { - "type": "array", - "items": { - "type": "object", - "required": [ - "name", - "value" - ], - "properties": { - "name": { - "type": "string" - }, - "value": { - "type": "string" - } - }, - "additionalProperties": false - } - }, - "hostAliases": { - "type": "array", - "items": { - "type": "object", - "properties": { - "ip": { - "type": "string" - }, - "hostnames": { - "type": "array", - "items": { - "type": "string" - } - } - }, - "additionalProperties": false - } - }, - "nodeSelector": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "podSecurityContext": { - "properties": { - "fsGroup": { - "format": "int64", - "type": "integer" - }, - "fsGroupChangePolicy": { - "type": "string" - }, - "runAsGroup": { - "format": "int64", - "type": "integer" - }, - "runAsNonRoot": { - "type": "boolean" - }, - "runAsUser": { - "format": "int64", - "type": "integer" - }, - "seLinuxOptions": { - "properties": { - "level": { - "type": "string" - }, - "role": { - "type": "string" - }, - "type": { - "type": "string" - }, - "user": { - "type": "string" - } - }, - "type": "object", - "additionalProperties": false - }, - "seccompProfile": { - "properties": { - "localhostProfile": { - "type": "string" - }, - "type": { - "enum": [ - "RuntimeDefault", - "Unconfined", - "Localhost" - ], - "type": "string" - } - }, - "type": "object", - "additionalProperties": false - }, - "supplementalGroups": { - "items": { - "format": "int64", - "type": "integer" - }, - "type": "array" - } - }, - "type": "object", - "additionalProperties": false - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - }, - "serviceAccount": { - "type": "object", - "properties": { - "create": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "annotations": { - "type": "object", - "additionalProperties": { - "type": "string" - } - } - }, - "additionalProperties": false - }, - "serviceMonitors": { - "type": "object", - "properties": { - "enabled": { - "type": "boolean" - } - }, - "additionalProperties": false - }, - "tolerations": { - "type": "array", - "items": { - "properties": { - "effect": { - "type": "string", - "enum": [ - "NoSchedule", - "PreferNoSchedule", - "NoExecute" - ] - }, - "key": { - "type": "string" - }, - "operator": { - "type": "string" - }, - "tolerationSeconds": { - "type": "number" - }, - "value": { - "type": "string" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "workers": { - "type": "object", - "properties": { - "appservice": { - "properties": { - "enabled": { - "type": "boolean" - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "background": { - "properties": { - "enabled": { - "type": "boolean" - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "client-reader": { - "required": [ - "instances" - ], - "properties": { - "enabled": { - "type": "boolean" - }, - "instances": { - "type": "integer", - "minimum": 1 - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "encryption": { - "properties": { - "enabled": { - "type": "boolean" - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "event-creator": { - "required": [ - "instances" - ], - "properties": { - "enabled": { - "type": "boolean" - }, - "instances": { - "type": "integer", - "minimum": 1 - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "event-persister": { - "required": [ - "instances" - ], - "properties": { - "enabled": { - "type": "boolean" - }, - "instances": { - "type": "integer", - "minimum": 1 - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "federation-reader": { - "required": [ - "instances" - ], - "properties": { - "enabled": { - "type": "boolean" - }, - "instances": { - "type": "integer", - "minimum": 1 - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "federation-sender": { - "required": [ - "instances" - ], - "properties": { - "enabled": { - "type": "boolean" - }, - "instances": { - "type": "integer", - "minimum": 1 - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "initial-synchrotron": { - "required": [ - "instances" - ], - "properties": { - "enabled": { - "type": "boolean" - }, - "instances": { - "type": "integer", - "minimum": 1 - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "media-repository": { - "properties": { - "enabled": { - "type": "boolean" - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "presence-writer": { - "properties": { - "enabled": { - "type": "boolean" - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "pusher": { - "required": [ - "instances" - ], - "properties": { - "enabled": { - "type": "boolean" - }, - "instances": { - "type": "integer", - "minimum": 1 - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "receipts-account": { - "properties": { - "enabled": { - "type": "boolean" - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "sliding-sync": { - "required": [ - "instances" - ], - "properties": { - "enabled": { - "type": "boolean" - }, - "instances": { - "type": "integer", - "minimum": 1 - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "sso-login": { - "properties": { - "enabled": { - "type": "boolean" - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "synchrotron": { - "required": [ - "instances" - ], - "properties": { - "enabled": { - "type": "boolean" - }, - "instances": { - "type": "integer", - "minimum": 1 - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "typing-persister": { - "properties": { - "enabled": { - "type": "boolean" - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "user-dir": { - "properties": { - "enabled": { - "type": "boolean" - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - } - }, - "additionalProperties": false - }, - "haproxy": { - "type": "object", - "properties": { - "replicas": { - "minimum": 1, - "type": "integer" - }, "image": { "type": "object", "required": [ @@ -1690,6 +608,43 @@ "type": "object", "additionalProperties": false }, + "extraEnv": { + "type": "array", + "items": { + "type": "object", + "required": [ + "name", + "value" + ], + "properties": { + "name": { + "type": "string" + }, + "value": { + "type": "string" + } + }, + "additionalProperties": false + } + }, + "hostAliases": { + "type": "array", + "items": { + "type": "object", + "properties": { + "ip": { + "type": "string" + }, + "hostnames": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "additionalProperties": false + } + }, "nodeSelector": { "type": "object", "additionalProperties": { @@ -1851,265 +806,1380 @@ "type": "object", "additionalProperties": false } - } - }, - "additionalProperties": false - }, - "redis": { - "type": "object", - "properties": { - "image": { + }, + "workers": { "type": "object", - "required": [ - "repository" - ], "properties": { - "registry": { - "type": "string" - }, - "repository": { - "type": "string" - }, - "tag": { - "type": "string" - }, - "digest": { - "type": "string" - }, - "pullPolicy": { - "type": "string", - "enum": [ - "Always", - "IfNotPresent", - "Never" - ] - }, - "pullSecrets": { - "type": "array", - "items": { - "type": "object", - "properties": { - "name": { - "type": "string" - } + "appservice": { + "properties": { + "enabled": { + "type": "boolean" }, - "additionalProperties": false + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "background": { + "properties": { + "enabled": { + "type": "boolean" + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "client-reader": { + "required": [ + "instances" + ], + "properties": { + "enabled": { + "type": "boolean" + }, + "instances": { + "type": "integer", + "minimum": 1 + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "encryption": { + "properties": { + "enabled": { + "type": "boolean" + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "event-creator": { + "required": [ + "instances" + ], + "properties": { + "enabled": { + "type": "boolean" + }, + "instances": { + "type": "integer", + "minimum": 1 + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "event-persister": { + "required": [ + "instances" + ], + "properties": { + "enabled": { + "type": "boolean" + }, + "instances": { + "type": "integer", + "minimum": 1 + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "federation-reader": { + "required": [ + "instances" + ], + "properties": { + "enabled": { + "type": "boolean" + }, + "instances": { + "type": "integer", + "minimum": 1 + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "federation-sender": { + "required": [ + "instances" + ], + "properties": { + "enabled": { + "type": "boolean" + }, + "instances": { + "type": "integer", + "minimum": 1 + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "initial-synchrotron": { + "required": [ + "instances" + ], + "properties": { + "enabled": { + "type": "boolean" + }, + "instances": { + "type": "integer", + "minimum": 1 + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "media-repository": { + "properties": { + "enabled": { + "type": "boolean" + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "presence-writer": { + "properties": { + "enabled": { + "type": "boolean" + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "pusher": { + "required": [ + "instances" + ], + "properties": { + "enabled": { + "type": "boolean" + }, + "instances": { + "type": "integer", + "minimum": 1 + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "receipts-account": { + "properties": { + "enabled": { + "type": "boolean" + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "sliding-sync": { + "required": [ + "instances" + ], + "properties": { + "enabled": { + "type": "boolean" + }, + "instances": { + "type": "integer", + "minimum": 1 + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "sso-login": { + "properties": { + "enabled": { + "type": "boolean" + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "synchrotron": { + "required": [ + "instances" + ], + "properties": { + "enabled": { + "type": "boolean" + }, + "instances": { + "type": "integer", + "minimum": 1 + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "typing-persister": { + "properties": { + "enabled": { + "type": "boolean" + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "user-dir": { + "properties": { + "enabled": { + "type": "boolean" + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + } + }, + "additionalProperties": false + }, + "haproxy": { + "type": "object", + "properties": { + "replicas": { + "minimum": 1, + "type": "integer" + }, + "image": { + "type": "object", + "required": [ + "repository" + ], + "properties": { + "registry": { + "type": "string" + }, + "repository": { + "type": "string" + }, + "tag": { + "type": "string" + }, + "digest": { + "type": "string" + }, + "pullPolicy": { + "type": "string", + "enum": [ + "Always", + "IfNotPresent", + "Never" + ] + }, + "pullSecrets": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string" + } + }, + "additionalProperties": false + } + } + }, + "additionalProperties": false + }, + "labels": { + "type": "object", + "additionalProperties": { + "type": "string" } - } - }, - "additionalProperties": false - }, - "labels": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "annotations": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "containersSecurityContext": { - "properties": { - "allowPrivilegeEscalation": { - "type": "boolean" - }, - "capabilities": { - "properties": { - "add": { - "items": { - "type": "string" - }, - "type": "array" - }, - "drop": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object", - "additionalProperties": false - }, - "readOnlyRootFilesystem": { - "type": "boolean" - }, - "seccompProfile": { - "properties": { - "localhostProfile": { - "type": "string" - }, - "type": { - "enum": [ - "RuntimeDefault", - "Unconfined", - "Localhost" - ], - "type": "string" - } - }, - "type": "object", - "additionalProperties": false - } - }, - "type": "object", - "additionalProperties": false - }, - "nodeSelector": { - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "podSecurityContext": { - "properties": { - "fsGroup": { - "format": "int64", - "type": "integer" - }, - "fsGroupChangePolicy": { - "type": "string" - }, - "runAsGroup": { - "format": "int64", - "type": "integer" - }, - "runAsNonRoot": { - "type": "boolean" - }, - "runAsUser": { - "format": "int64", - "type": "integer" - }, - "seLinuxOptions": { - "properties": { - "level": { - "type": "string" - }, - "role": { - "type": "string" - }, - "type": { - "type": "string" - }, - "user": { - "type": "string" - } - }, - "type": "object", - "additionalProperties": false - }, - "seccompProfile": { - "properties": { - "localhostProfile": { - "type": "string" - }, - "type": { - "enum": [ - "RuntimeDefault", - "Unconfined", - "Localhost" - ], - "type": "string" - } - }, - "type": "object", - "additionalProperties": false - }, - "supplementalGroups": { - "items": { - "format": "int64", - "type": "integer" - }, - "type": "array" - } - }, - "type": "object", - "additionalProperties": false - }, - "resources": { - "properties": { - "limits": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - }, - "requests": { - "additionalProperties": { - "anyOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ], - "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" - }, - "type": "object" - } - }, - "type": "object", - "additionalProperties": false - }, - "serviceAccount": { - "type": "object", - "properties": { - "create": { - "type": "boolean" - }, - "name": { - "type": "string" }, "annotations": { "type": "object", "additionalProperties": { "type": "string" } + }, + "containersSecurityContext": { + "properties": { + "allowPrivilegeEscalation": { + "type": "boolean" + }, + "capabilities": { + "properties": { + "add": { + "items": { + "type": "string" + }, + "type": "array" + }, + "drop": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object", + "additionalProperties": false + }, + "readOnlyRootFilesystem": { + "type": "boolean" + }, + "seccompProfile": { + "properties": { + "localhostProfile": { + "type": "string" + }, + "type": { + "enum": [ + "RuntimeDefault", + "Unconfined", + "Localhost" + ], + "type": "string" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "nodeSelector": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "podSecurityContext": { + "properties": { + "fsGroup": { + "format": "int64", + "type": "integer" + }, + "fsGroupChangePolicy": { + "type": "string" + }, + "runAsGroup": { + "format": "int64", + "type": "integer" + }, + "runAsNonRoot": { + "type": "boolean" + }, + "runAsUser": { + "format": "int64", + "type": "integer" + }, + "seLinuxOptions": { + "properties": { + "level": { + "type": "string" + }, + "role": { + "type": "string" + }, + "type": { + "type": "string" + }, + "user": { + "type": "string" + } + }, + "type": "object", + "additionalProperties": false + }, + "seccompProfile": { + "properties": { + "localhostProfile": { + "type": "string" + }, + "type": { + "enum": [ + "RuntimeDefault", + "Unconfined", + "Localhost" + ], + "type": "string" + } + }, + "type": "object", + "additionalProperties": false + }, + "supplementalGroups": { + "items": { + "format": "int64", + "type": "integer" + }, + "type": "array" + } + }, + "type": "object", + "additionalProperties": false + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + }, + "serviceAccount": { + "type": "object", + "properties": { + "create": { + "type": "boolean" + }, + "name": { + "type": "string" + }, + "annotations": { + "type": "object", + "additionalProperties": { + "type": "string" + } + } + }, + "additionalProperties": false + }, + "serviceMonitors": { + "type": "object", + "properties": { + "enabled": { + "type": "boolean" + } + }, + "additionalProperties": false + }, + "tolerations": { + "type": "array", + "items": { + "properties": { + "effect": { + "type": "string", + "enum": [ + "NoSchedule", + "PreferNoSchedule", + "NoExecute" + ] + }, + "key": { + "type": "string" + }, + "operator": { + "type": "string" + }, + "tolerationSeconds": { + "type": "number" + }, + "value": { + "type": "string" + } + }, + "type": "object", + "additionalProperties": false + } } }, "additionalProperties": false }, - "tolerations": { - "type": "array", - "items": { - "properties": { - "effect": { - "type": "string", - "enum": [ - "NoSchedule", - "PreferNoSchedule", - "NoExecute" - ] + "redis": { + "type": "object", + "properties": { + "image": { + "type": "object", + "required": [ + "repository" + ], + "properties": { + "registry": { + "type": "string" + }, + "repository": { + "type": "string" + }, + "tag": { + "type": "string" + }, + "digest": { + "type": "string" + }, + "pullPolicy": { + "type": "string", + "enum": [ + "Always", + "IfNotPresent", + "Never" + ] + }, + "pullSecrets": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string" + } + }, + "additionalProperties": false + } + } }, - "key": { - "type": "string" - }, - "operator": { - "type": "string" - }, - "tolerationSeconds": { - "type": "number" - }, - "value": { + "additionalProperties": false + }, + "labels": { + "type": "object", + "additionalProperties": { "type": "string" } }, - "type": "object", - "additionalProperties": false - } + "annotations": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "containersSecurityContext": { + "properties": { + "allowPrivilegeEscalation": { + "type": "boolean" + }, + "capabilities": { + "properties": { + "add": { + "items": { + "type": "string" + }, + "type": "array" + }, + "drop": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object", + "additionalProperties": false + }, + "readOnlyRootFilesystem": { + "type": "boolean" + }, + "seccompProfile": { + "properties": { + "localhostProfile": { + "type": "string" + }, + "type": { + "enum": [ + "RuntimeDefault", + "Unconfined", + "Localhost" + ], + "type": "string" + } + }, + "type": "object", + "additionalProperties": false + } + }, + "type": "object", + "additionalProperties": false + }, + "nodeSelector": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "podSecurityContext": { + "properties": { + "fsGroup": { + "format": "int64", + "type": "integer" + }, + "fsGroupChangePolicy": { + "type": "string" + }, + "runAsGroup": { + "format": "int64", + "type": "integer" + }, + "runAsNonRoot": { + "type": "boolean" + }, + "runAsUser": { + "format": "int64", + "type": "integer" + }, + "seLinuxOptions": { + "properties": { + "level": { + "type": "string" + }, + "role": { + "type": "string" + }, + "type": { + "type": "string" + }, + "user": { + "type": "string" + } + }, + "type": "object", + "additionalProperties": false + }, + "seccompProfile": { + "properties": { + "localhostProfile": { + "type": "string" + }, + "type": { + "enum": [ + "RuntimeDefault", + "Unconfined", + "Localhost" + ], + "type": "string" + } + }, + "type": "object", + "additionalProperties": false + }, + "supplementalGroups": { + "items": { + "format": "int64", + "type": "integer" + }, + "type": "array" + } + }, + "type": "object", + "additionalProperties": false + }, + "resources": { + "properties": { + "limits": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + }, + "requests": { + "additionalProperties": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ], + "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$" + }, + "type": "object" + } + }, + "type": "object", + "additionalProperties": false + }, + "serviceAccount": { + "type": "object", + "properties": { + "create": { + "type": "boolean" + }, + "name": { + "type": "string" + }, + "annotations": { + "type": "object", + "additionalProperties": { + "type": "string" + } + } + }, + "additionalProperties": false + }, + "tolerations": { + "type": "array", + "items": { + "properties": { + "effect": { + "type": "string", + "enum": [ + "NoSchedule", + "PreferNoSchedule", + "NoExecute" + ] + }, + "key": { + "type": "string" + }, + "operator": { + "type": "string" + }, + "tolerationSeconds": { + "type": "number" + }, + "value": { + "type": "string" + } + }, + "type": "object", + "additionalProperties": false + } + } + }, + "additionalProperties": false } }, "additionalProperties": false diff --git a/charts/synapse/values.yaml b/charts/synapse/values.yaml index 1e9707bc..7bfa2185 100644 --- a/charts/synapse/values.yaml +++ b/charts/synapse/values.yaml @@ -3,27 +3,20 @@ # SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial # This file is generated. Do not edit directly. Edit source/values.yaml.j2 instead to make changes +## ESS specific globals, namespaced to avoid interference with other charts +ess: + ## The server name of the Matrix Stack. This gets embedded in user IDs & room IDs + ## It can not change after the initial deployment. + # serverName: ess.localhost + ## Labels to add to all manifest in this chart + labels: {} - -## Global values available to all sub-charts -global: - ## ESS specific globals, namespaced to avoid interference with other charts - ess: - ## The server name of the Matrix Stack. This gets embedded in user IDs & room IDs - ## It can not change after the initial deployment. - # server_name: ess.localhost - - ## Labels to add to all manifest in this chart and all sub-charts - labels: {} - - ## A list of Secrets in this namespace to use as pull Secrets. - ## Ignored if a given component specifies its own pull Secrets. - ## e.g. - ## imagePullSecrets: - ## - name: ess-pull-secret - imagePullSecrets: [] - - + ## A list of Secrets in this namespace to use as pull Secrets. + ## Ignored if a given component specifies its own pull Secrets. + ## e.g. + ## imagePullSecrets: + ## - name: ess-pull-secret + imagePullSecrets: [] ## Details of the Postgres Database to use postgres: ## PostgreSQL database host @@ -52,464 +45,245 @@ postgres: ## secretKey: key-in-secret password: {} -## Configures the media store for Synapse -media: - - ## Configures the PersistentVolumeClaim to be used for storage - storage: - ## Name of an existing PersistentVolumeClaim in this namespace that should be used - # existingClaim: - - ## The size of a PersistentVolumeClaim to be constructed - ## Ignored if existingClaim is provided - size: 10Gi - - ## The StorageClass to be used by the constructed PersistentVolumeClaim. - ## Will use the cluster default if not provided - ## Ignored if existingClaim is provided - # storageClass: - - -## Key used to sign events and federation requests. -## This needs to be the full signing key starting `ed25519 ...`. -## It can either be provided inline in the Helm chart e.g.: -## signingKey: -## value: SecretValue -## -## Or it can be provided via an existing Secret e.g.: -## signingKey: -## secret: existing-secret -## secretKey: key-in-secret -signingKey: {} - -## Shared Secret to registering users without having any users provisioned. -## It can either be provided inline in the Helm chart e.g.: -## registrationSharedSecret: -## value: SecretValue -## -## Or it can be provided via an existing Secret e.g.: -## registrationSharedSecret: -## secret: existing-secret -## secretKey: key-in-secret -registrationSharedSecret: {} - -## Secret used to sign Synapse issued tokens. -## It can either be provided inline in the Helm chart e.g.: -## macaroon: -## value: SecretValue -## -## Or it can be provided via an existing Secret e.g.: -## macaroon: -## secret: existing-secret -## secretKey: key-in-secret -macaroon: {} - -## Additional configuration to provide to all Synapse processes. -## This can be provided in-line in the Helm Chart and/or via an existing Secret -## e.g. -## additional: -## config: | -## allow_guest_access: true -## -## or -## additional: -## configSecret: custom-synapse-config -## configSecretKey: shared.yaml -additional: {} - -## Details of Application Service registration files to give to Synapse -## e.g. -## appservices: -## - registrationFileConfigMap: test-appservice -appservices: [] - -## Additional Synapse processes managed by this chart -## e.g. -## workers: -## client-reader: -## instances: 2 -## event-creator: {} -workers: - - appservice: - ## Set to true to deploy a single instance of this worker - enabled: false - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - background: - ## Set to true to deploy a single instance of this worker - enabled: false - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - client-reader: - ## Set to true to deploy instances of this worker - enabled: false - - ## The number of instances of this worker to run - instances: 1 - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - encryption: - ## Set to true to deploy a single instance of this worker - enabled: false - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - event-creator: - ## Set to true to deploy instances of this worker - enabled: false - - ## The number of instances of this worker to run - instances: 1 - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - event-persister: - ## Set to true to deploy instances of this worker - enabled: false - - ## The number of instances of this worker to run - instances: 1 - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - federation-reader: - ## Set to true to deploy instances of this worker - enabled: false - - ## The number of instances of this worker to run - instances: 1 - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - federation-sender: - ## Set to true to deploy instances of this worker - enabled: false - - ## The number of instances of this worker to run - instances: 1 - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - initial-synchrotron: - ## Set to true to deploy instances of this worker - enabled: false - - ## The number of instances of this worker to run - instances: 1 - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - media-repository: - ## Set to true to deploy a single instance of this worker - enabled: false - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - presence-writer: - ## Set to true to deploy a single instance of this worker - enabled: false - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - pusher: - ## Set to true to deploy instances of this worker - enabled: false - - ## The number of instances of this worker to run - instances: 1 - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - receipts-account: - ## Set to true to deploy a single instance of this worker - enabled: false - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - sliding-sync: - ## Set to true to deploy instances of this worker - enabled: false - - ## The number of instances of this worker to run - instances: 1 - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - sso-login: - ## Set to true to deploy a single instance of this worker - enabled: false - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - synchrotron: - ## Set to true to deploy instances of this worker - enabled: false - - ## The number of instances of this worker to run - instances: 1 - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - typing-persister: - ## Set to true to deploy a single instance of this worker - enabled: false - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - - user-dir: - ## Set to true to deploy a single instance of this worker - enabled: false - - ## Resources for this worker. - ## If omitted the global Synapse resources are used - # resources: {} - -## Synapse's logging settings -logging: - ## The maximum level of Synapse log output before any overrides - rootLevel: INFO - - ## Override the log level of specific loggers - ## e.g. - ## levelOverrides: - ## synapse.util.caches.lrucache: WARNING - levelOverrides: {} - -# Details of the image to be used -image: - ## The host and (optional) port of the container image registry for this component. - ## If not specified Docker Hub is implied - registry: docker.io - - ## The path in the registry where the container image is located - repository: matrixdotorg/synapse - - ## The tag of the container image to use. - ## Defaults to the Chart's appVersion if not set - # tag: - - ## Container digest to use. Used to pull the image instead of the image tag / Chart appVersion if set - # digest: - - ## Whether the image should be pulled on container startup. Valid values are Always, IfNotPresent and Never - ## If this isn't provided it defaults to Always when using the image tag / Chart appVersion or - ## IfNotPresent if using a digest - # pullPolicy: - - ## A list of pull secrets to use for this image - ## e.g. - ## pullSecrets: - ## - name: dockerhub - pullSecrets: [] - -## How this ingress should be constructed -ingress: - ## What hostname should be used for this Ingress - # host: - - ## Annotations to be added to this Ingress - annotations: {} - - ## What Ingress Class Name should be used for this Ingress - # className: - - ## The name of the Secret containing the TLS certificate and key should be used for this Ingress - # tlsSecret: - - ## How the service behind the ingress is constructed - service: - type: ClusterIP - -## Labels to add to all manifest in this chart -labels: {} - -## Defines the annotations to add to the workload -# annotations: {} - -## A subset of SecurityContext. ContainersSecurityContext holds pod-level security attributes and common container settings -containersSecurityContext: - ## Controls whether a process can gain more privileges than its parent process. - ## This bool directly controls whether the no_new_privs flag gets set on the container process. - ## allowPrivilegeEscalation is always true when the container is run as privileged, or has CAP_SYS_ADMIN - allowPrivilegeEscalation: false - - ## Give a process some privileges, but not all the privileges of the root user. - capabilities: - ## Privileges to add. - # add: [] - ## Privileges to drop. - drop: - - ALL - - ## Mounts the container's root filesystem as read-only. - readOnlyRootFilesystem: true - - ## To set the Seccomp profile for a Container, include the seccompProfile field in the securityContext section of your Pod or Container manifest. - ## The seccompProfile field is a SeccompProfile object consisting of type and localhostProfile. Valid options for type include RuntimeDefault, Unconfined, and Localhost. - ## localhostProfile must only be set set if type Localhost. It indicates the path of the pre-configured profile on the node, relative to the kubelet's configured Seccomp profile location (configured with the --root-dir flag). - seccompProfile: - type: RuntimeDefault - -## Defines additional environment variables to be injected onto this workload -## e.g. -## extraEnv: -## - name: FOO -## value: "bar" -extraEnv: [] - -## The list of hosts aliases to configure on the pod spec. -## It should be avoid as much as possible to use this feature. -## Please prefer using an DNS entry to resolve your hostnames. -## This can be used as a workaround when entries cannot be resolved using DNS, for example for our automated testings. -## e.g. -## hostAliases: -## - ip: 192.0.2.1 # An IP resolution to add to /etc/hosts -## # A list of hostnames to be associated with the above IP -## hostnames: -## - ess.localhost -## - synapse.ess.localhost -hostAliases: [] - -## NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ -# nodeSelector: {} - -## A subset of PodSecurityContext. PodSecurityContext holds pod-level security attributes and common container settings -podSecurityContext: - ## A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to - ## change the ownership of that volume to be owned by the pod: - ## - ## 1. The owning GID will be the FSGroup - ## 2. The setgid bit is set (new files created in the volume will be owned by FSGroup)## 3. The permission bits are OR'd with rw-rw---- - ## - ## If unset, the Kubelet will not modify the ownership and permissions of any volume. - fsGroup: 10091 - - ## fsGroupChangePolicy defines behavior of changing ownership and permission of the volume before being exposed inside Pod. - ## This field will only apply to volume types which support fsGroup based ownership(and permissions). - ## It will have no effect on ephemeral volume types such as: secret, configmaps and emptydir. Valid values are "OnRootMismatch" and "Always". If not specified, "Always" is used. - # fsGroupChangePolicy: - - ## The GID to run the entrypoint of the container process. Uses runtime default if unset. - runAsGroup: 10091 - - ## Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. - runAsNonRoot: true - - ## The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. - runAsUser: 10091 - - ## SELinuxOptions are the labels to be applied to all the pod containers - # seLinuxOptions: - ## Level is SELinux level label that applies to the container. - # level: - - ## Role is a SELinux role label that applies to the container. - # role: - - ## Type is a SELinux type label that applies to the container. - # type: - - ## User is a SELinux user label that applies to the container. - # user: - - ## "To set the Seccomp profile for a Container, include the seccompProfile field in the securityContext section of your Pod or Container manifest. - ## The seccompProfile field is a SeccompProfile object consisting of type and localhostProfile. - ## Valid options for type include RuntimeDefault, Unconfined, and Localhost. localhostProfile must only be set set if type Localhost. - ## It indicates the path of the pre-configured profile on the node, relative to the kubelet's configured Seccomp profile location (configured with the --root-dir flag). - # seccompProfile: - # localhostProfile: - # type: - - ## A list of groups applied to the first process run in each container, in addition to the container's primary GID. - ## If unspecified, no groups will be added to any container. - supplementalGroups: [] - -## Kubernetes resources to allocate to each instance. -resources: - ## Requests describes the minimum amount of compute resources required. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ - requests: - memory: 100Mi - cpu: 100m - - ## Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ - limits: - memory: 4Gi - -## Controls configuration of the ServiceAccount for this component -serviceAccount: - ## Whether a ServiceAccount should be created by the chart or not - create: true - - ## What name to give the ServiceAccount. If not provided the chart will provide the name automatically - name: "" - - ## Annotations to add to the service account - annotations: {} - -## Whether to deploy ServiceMonitors into the cluster for this component -## Requires the ServiceMonitor CRDs to be in the cluster -serviceMonitors: +synapse: enabled: true + ## Configures the media store for Synapse + media: + ## Configures the PersistentVolumeClaim to be used for storage + storage: + ## Name of an existing PersistentVolumeClaim in this namespace that should be used + # existingClaim: -## Workload tolerations -## The pod this Toleration is attached to tolerates any taint that matches the triple using the matching operator . -## -## * effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute. -## * key is the taint key that the toleration applies to. Empty means match all taint keys. If the key is empty, operator must be Exists; this combination means to match all values and all keys. -## * operator represents a key's relationship to the value. Valid operators are Exists and Equal. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category. -## * value is the taint value the toleration matches to. If the operator is Exists, the value should be empty, otherwise just a regular string. -## -## * tolerationSeconds represents the period of time the toleration (which must be of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, it is not set, which means tolerate the taint forever (do not evict). Zero and negative values will be treated as 0 (evict immediately) by the system. -## e.g. -## tolerations: -## - effect: -## key: -## operator: -## value: + ## The size of a PersistentVolumeClaim to be constructed + ## Ignored if existingClaim is provided + size: 10Gi -tolerations: [] + ## The StorageClass to be used by the constructed PersistentVolumeClaim. + ## Will use the cluster default if not provided + ## Ignored if existingClaim is provided + # storageClass: + ## Key used to sign events and federation requests. + ## This needs to be the full signing key starting `ed25519 ...`. + ## It can either be provided inline in the Helm chart e.g.: + ## signingKey: + ## value: SecretValue + ## + ## Or it can be provided via an existing Secret e.g.: + ## signingKey: + ## secret: existing-secret + ## secretKey: key-in-secret + signingKey: {} + ## Shared Secret to registering users without having any users provisioned. + ## It can either be provided inline in the Helm chart e.g.: + ## registrationSharedSecret: + ## value: SecretValue + ## + ## Or it can be provided via an existing Secret e.g.: + ## registrationSharedSecret: + ## secret: existing-secret + ## secretKey: key-in-secret + registrationSharedSecret: {} + ## Secret used to sign Synapse issued tokens. + ## It can either be provided inline in the Helm chart e.g.: + ## macaroon: + ## value: SecretValue + ## + ## Or it can be provided via an existing Secret e.g.: + ## macaroon: + ## secret: existing-secret + ## secretKey: key-in-secret + macaroon: {} -haproxy: - replicas: 2 + ## Additional configuration to provide to all Synapse processes. + ## This can be provided in-line in the Helm Chart and/or via an existing Secret + ## e.g. + ## additional: + ## config: | + ## allow_guest_access: true + ## + ## or + ## additional: + ## configSecret: custom-synapse-config + ## configSecretKey: shared.yaml + additional: {} + ## Details of Application Service registration files to give to Synapse + ## e.g. + ## appservices: + ## - registrationFileConfigMap: test-appservice + appservices: [] + + ## Additional Synapse processes managed by this chart + ## e.g. + ## workers: + ## client-reader: + ## instances: 2 + ## event-creator: {} + workers: + appservice: + ## Set to true to deploy a single instance of this worker + enabled: false + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + background: + ## Set to true to deploy a single instance of this worker + enabled: false + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + client-reader: + ## Set to true to deploy instances of this worker + enabled: false + + ## The number of instances of this worker to run + instances: 1 + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + encryption: + ## Set to true to deploy a single instance of this worker + enabled: false + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + event-creator: + ## Set to true to deploy instances of this worker + enabled: false + + ## The number of instances of this worker to run + instances: 1 + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + event-persister: + ## Set to true to deploy instances of this worker + enabled: false + + ## The number of instances of this worker to run + instances: 1 + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + federation-reader: + ## Set to true to deploy instances of this worker + enabled: false + + ## The number of instances of this worker to run + instances: 1 + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + federation-sender: + ## Set to true to deploy instances of this worker + enabled: false + + ## The number of instances of this worker to run + instances: 1 + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + initial-synchrotron: + ## Set to true to deploy instances of this worker + enabled: false + + ## The number of instances of this worker to run + instances: 1 + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + media-repository: + ## Set to true to deploy a single instance of this worker + enabled: false + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + presence-writer: + ## Set to true to deploy a single instance of this worker + enabled: false + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + pusher: + ## Set to true to deploy instances of this worker + enabled: false + + ## The number of instances of this worker to run + instances: 1 + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + receipts-account: + ## Set to true to deploy a single instance of this worker + enabled: false + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + sliding-sync: + ## Set to true to deploy instances of this worker + enabled: false + + ## The number of instances of this worker to run + instances: 1 + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + sso-login: + ## Set to true to deploy a single instance of this worker + enabled: false + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + synchrotron: + ## Set to true to deploy instances of this worker + enabled: false + + ## The number of instances of this worker to run + instances: 1 + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + typing-persister: + ## Set to true to deploy a single instance of this worker + enabled: false + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + user-dir: + ## Set to true to deploy a single instance of this worker + enabled: false + + ## Resources for this worker. + ## If omitted the global Synapse resources are used + # resources: {} + + ## Synapse's logging settings + logging: + ## The maximum level of Synapse log output before any overrides + rootLevel: INFO + + ## Override the log level of specific loggers + ## e.g. + ## levelOverrides: + ## synapse.util.caches.lrucache: WARNING + levelOverrides: {} # Details of the image to be used image: ## The host and (optional) port of the container image registry for this component. @@ -517,11 +291,11 @@ haproxy: registry: docker.io ## The path in the registry where the container image is located - repository: library/haproxy + repository: matrixdotorg/synapse ## The tag of the container image to use. ## Defaults to the Chart's appVersion if not set - tag: 3.0-alpine + # tag: ## Container digest to use. Used to pull the image instead of the image tag / Chart appVersion if set # digest: @@ -536,13 +310,27 @@ haproxy: ## pullSecrets: ## - name: dockerhub pullSecrets: [] + ## How this ingress should be constructed + ingress: + ## What hostname should be used for this Ingress + # host: + ## Annotations to be added to this Ingress + annotations: {} + + ## What Ingress Class Name should be used for this Ingress + # className: + + ## The name of the Secret containing the TLS certificate and key should be used for this Ingress + # tlsSecret: + + ## How the service behind the ingress is constructed + service: + type: ClusterIP ## Labels to add to all manifest in this chart labels: {} - ## Defines the annotations to add to the workload # annotations: {} - ## A subset of SecurityContext. ContainersSecurityContext holds pod-level security attributes and common container settings containersSecurityContext: ## Controls whether a process can gain more privileges than its parent process. @@ -566,10 +354,26 @@ haproxy: ## localhostProfile must only be set set if type Localhost. It indicates the path of the pre-configured profile on the node, relative to the kubelet's configured Seccomp profile location (configured with the --root-dir flag). seccompProfile: type: RuntimeDefault - + ## Defines additional environment variables to be injected onto this workload + ## e.g. + ## extraEnv: + ## - name: FOO + ## value: "bar" + extraEnv: [] + ## The list of hosts aliases to configure on the pod spec. + ## It should be avoid as much as possible to use this feature. + ## Please prefer using an DNS entry to resolve your hostnames. + ## This can be used as a workaround when entries cannot be resolved using DNS, for example for our automated testings. + ## e.g. + ## hostAliases: + ## - ip: 192.0.2.1 # An IP resolution to add to /etc/hosts + ## # A list of hostnames to be associated with the above IP + ## hostnames: + ## - ess.localhost + ## - synapse.ess.localhost + hostAliases: [] ## NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ # nodeSelector: {} - ## A subset of PodSecurityContext. PodSecurityContext holds pod-level security attributes and common container settings podSecurityContext: ## A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to @@ -579,7 +383,7 @@ haproxy: ## 2. The setgid bit is set (new files created in the volume will be owned by FSGroup)## 3. The permission bits are OR'd with rw-rw---- ## ## If unset, the Kubelet will not modify the ownership and permissions of any volume. - fsGroup: 10001 + fsGroup: 10091 ## fsGroupChangePolicy defines behavior of changing ownership and permission of the volume before being exposed inside Pod. ## This field will only apply to volume types which support fsGroup based ownership(and permissions). @@ -587,13 +391,13 @@ haproxy: # fsGroupChangePolicy: ## The GID to run the entrypoint of the container process. Uses runtime default if unset. - runAsGroup: 10001 + runAsGroup: 10091 ## Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. runAsNonRoot: true ## The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. - runAsUser: 10001 + runAsUser: 10091 ## SELinuxOptions are the labels to be applied to all the pod containers # seLinuxOptions: @@ -620,7 +424,6 @@ haproxy: ## A list of groups applied to the first process run in each container, in addition to the container's primary GID. ## If unspecified, no groups will be added to any container. supplementalGroups: [] - ## Kubernetes resources to allocate to each instance. resources: ## Requests describes the minimum amount of compute resources required. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ @@ -630,8 +433,7 @@ haproxy: ## Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ limits: - memory: 200Mi - + memory: 4Gi ## Controls configuration of the ServiceAccount for this component serviceAccount: ## Whether a ServiceAccount should be created by the chart or not @@ -642,12 +444,10 @@ haproxy: ## Annotations to add to the service account annotations: {} - ## Whether to deploy ServiceMonitors into the cluster for this component ## Requires the ServiceMonitor CRDs to be in the cluster serviceMonitors: enabled: true - ## Workload tolerations ## The pod this Toleration is attached to tolerates any taint that matches the triple using the matching operator . ## @@ -666,154 +466,295 @@ haproxy: tolerations: [] -redis: - # Details of the image to be used - image: - ## The host and (optional) port of the container image registry for this component. - ## If not specified Docker Hub is implied - registry: docker.io + haproxy: + replicas: 2 + # Details of the image to be used + image: + ## The host and (optional) port of the container image registry for this component. + ## If not specified Docker Hub is implied + registry: docker.io - ## The path in the registry where the container image is located - repository: library/redis + ## The path in the registry where the container image is located + repository: library/haproxy - ## The tag of the container image to use. - ## Defaults to the Chart's appVersion if not set - tag: 7.4-alpine + ## The tag of the container image to use. + ## Defaults to the Chart's appVersion if not set + tag: 3.0-alpine - ## Container digest to use. Used to pull the image instead of the image tag / Chart appVersion if set - # digest: + ## Container digest to use. Used to pull the image instead of the image tag / Chart appVersion if set + # digest: - ## Whether the image should be pulled on container startup. Valid values are Always, IfNotPresent and Never - ## If this isn't provided it defaults to Always when using the image tag / Chart appVersion or - ## IfNotPresent if using a digest - # pullPolicy: + ## Whether the image should be pulled on container startup. Valid values are Always, IfNotPresent and Never + ## If this isn't provided it defaults to Always when using the image tag / Chart appVersion or + ## IfNotPresent if using a digest + # pullPolicy: - ## A list of pull secrets to use for this image + ## A list of pull secrets to use for this image + ## e.g. + ## pullSecrets: + ## - name: dockerhub + pullSecrets: [] + ## Labels to add to all manifest in this chart + labels: {} + ## Defines the annotations to add to the workload + # annotations: {} + ## A subset of SecurityContext. ContainersSecurityContext holds pod-level security attributes and common container settings + containersSecurityContext: + ## Controls whether a process can gain more privileges than its parent process. + ## This bool directly controls whether the no_new_privs flag gets set on the container process. + ## allowPrivilegeEscalation is always true when the container is run as privileged, or has CAP_SYS_ADMIN + allowPrivilegeEscalation: false + + ## Give a process some privileges, but not all the privileges of the root user. + capabilities: + ## Privileges to add. + # add: [] + ## Privileges to drop. + drop: + - ALL + + ## Mounts the container's root filesystem as read-only. + readOnlyRootFilesystem: true + + ## To set the Seccomp profile for a Container, include the seccompProfile field in the securityContext section of your Pod or Container manifest. + ## The seccompProfile field is a SeccompProfile object consisting of type and localhostProfile. Valid options for type include RuntimeDefault, Unconfined, and Localhost. + ## localhostProfile must only be set set if type Localhost. It indicates the path of the pre-configured profile on the node, relative to the kubelet's configured Seccomp profile location (configured with the --root-dir flag). + seccompProfile: + type: RuntimeDefault + ## NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ + # nodeSelector: {} + ## A subset of PodSecurityContext. PodSecurityContext holds pod-level security attributes and common container settings + podSecurityContext: + ## A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to + ## change the ownership of that volume to be owned by the pod: + ## + ## 1. The owning GID will be the FSGroup + ## 2. The setgid bit is set (new files created in the volume will be owned by FSGroup)## 3. The permission bits are OR'd with rw-rw---- + ## + ## If unset, the Kubelet will not modify the ownership and permissions of any volume. + fsGroup: 10001 + + ## fsGroupChangePolicy defines behavior of changing ownership and permission of the volume before being exposed inside Pod. + ## This field will only apply to volume types which support fsGroup based ownership(and permissions). + ## It will have no effect on ephemeral volume types such as: secret, configmaps and emptydir. Valid values are "OnRootMismatch" and "Always". If not specified, "Always" is used. + # fsGroupChangePolicy: + + ## The GID to run the entrypoint of the container process. Uses runtime default if unset. + runAsGroup: 10001 + + ## Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. + runAsNonRoot: true + + ## The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. + runAsUser: 10001 + + ## SELinuxOptions are the labels to be applied to all the pod containers + # seLinuxOptions: + ## Level is SELinux level label that applies to the container. + # level: + + ## Role is a SELinux role label that applies to the container. + # role: + + ## Type is a SELinux type label that applies to the container. + # type: + + ## User is a SELinux user label that applies to the container. + # user: + + ## "To set the Seccomp profile for a Container, include the seccompProfile field in the securityContext section of your Pod or Container manifest. + ## The seccompProfile field is a SeccompProfile object consisting of type and localhostProfile. + ## Valid options for type include RuntimeDefault, Unconfined, and Localhost. localhostProfile must only be set set if type Localhost. + ## It indicates the path of the pre-configured profile on the node, relative to the kubelet's configured Seccomp profile location (configured with the --root-dir flag). + # seccompProfile: + # localhostProfile: + # type: + + ## A list of groups applied to the first process run in each container, in addition to the container's primary GID. + ## If unspecified, no groups will be added to any container. + supplementalGroups: [] + ## Kubernetes resources to allocate to each instance. + resources: + ## Requests describes the minimum amount of compute resources required. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + requests: + memory: 100Mi + cpu: 100m + + ## Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + limits: + memory: 200Mi + ## Controls configuration of the ServiceAccount for this component + serviceAccount: + ## Whether a ServiceAccount should be created by the chart or not + create: true + + ## What name to give the ServiceAccount. If not provided the chart will provide the name automatically + name: "" + + ## Annotations to add to the service account + annotations: {} + ## Whether to deploy ServiceMonitors into the cluster for this component + ## Requires the ServiceMonitor CRDs to be in the cluster + serviceMonitors: + enabled: true + ## Workload tolerations + ## The pod this Toleration is attached to tolerates any taint that matches the triple using the matching operator . + ## + ## * effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute. + ## * key is the taint key that the toleration applies to. Empty means match all taint keys. If the key is empty, operator must be Exists; this combination means to match all values and all keys. + ## * operator represents a key's relationship to the value. Valid operators are Exists and Equal. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category. + ## * value is the taint value the toleration matches to. If the operator is Exists, the value should be empty, otherwise just a regular string. + ## + ## * tolerationSeconds represents the period of time the toleration (which must be of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, it is not set, which means tolerate the taint forever (do not evict). Zero and negative values will be treated as 0 (evict immediately) by the system. ## e.g. - ## pullSecrets: - ## - name: dockerhub - pullSecrets: [] + ## tolerations: + ## - effect: + ## key: + ## operator: + ## value: - ## Labels to add to all manifest in this chart - labels: {} + tolerations: [] - ## Defines the annotations to add to the workload - # annotations: {} + redis: + # Details of the image to be used + image: + ## The host and (optional) port of the container image registry for this component. + ## If not specified Docker Hub is implied + registry: docker.io - ## A subset of SecurityContext. ContainersSecurityContext holds pod-level security attributes and common container settings - containersSecurityContext: - ## Controls whether a process can gain more privileges than its parent process. - ## This bool directly controls whether the no_new_privs flag gets set on the container process. - ## allowPrivilegeEscalation is always true when the container is run as privileged, or has CAP_SYS_ADMIN - allowPrivilegeEscalation: false + ## The path in the registry where the container image is located + repository: library/redis - ## Give a process some privileges, but not all the privileges of the root user. - capabilities: - ## Privileges to add. - # add: [] - ## Privileges to drop. - drop: - - ALL + ## The tag of the container image to use. + ## Defaults to the Chart's appVersion if not set + tag: 7.4-alpine - ## Mounts the container's root filesystem as read-only. - readOnlyRootFilesystem: true + ## Container digest to use. Used to pull the image instead of the image tag / Chart appVersion if set + # digest: - ## To set the Seccomp profile for a Container, include the seccompProfile field in the securityContext section of your Pod or Container manifest. - ## The seccompProfile field is a SeccompProfile object consisting of type and localhostProfile. Valid options for type include RuntimeDefault, Unconfined, and Localhost. - ## localhostProfile must only be set set if type Localhost. It indicates the path of the pre-configured profile on the node, relative to the kubelet's configured Seccomp profile location (configured with the --root-dir flag). - seccompProfile: - type: RuntimeDefault + ## Whether the image should be pulled on container startup. Valid values are Always, IfNotPresent and Never + ## If this isn't provided it defaults to Always when using the image tag / Chart appVersion or + ## IfNotPresent if using a digest + # pullPolicy: - ## NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ - # nodeSelector: {} + ## A list of pull secrets to use for this image + ## e.g. + ## pullSecrets: + ## - name: dockerhub + pullSecrets: [] + ## Labels to add to all manifest in this chart + labels: {} + ## Defines the annotations to add to the workload + # annotations: {} + ## A subset of SecurityContext. ContainersSecurityContext holds pod-level security attributes and common container settings + containersSecurityContext: + ## Controls whether a process can gain more privileges than its parent process. + ## This bool directly controls whether the no_new_privs flag gets set on the container process. + ## allowPrivilegeEscalation is always true when the container is run as privileged, or has CAP_SYS_ADMIN + allowPrivilegeEscalation: false - ## A subset of PodSecurityContext. PodSecurityContext holds pod-level security attributes and common container settings - podSecurityContext: - ## A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to - ## change the ownership of that volume to be owned by the pod: + ## Give a process some privileges, but not all the privileges of the root user. + capabilities: + ## Privileges to add. + # add: [] + ## Privileges to drop. + drop: + - ALL + + ## Mounts the container's root filesystem as read-only. + readOnlyRootFilesystem: true + + ## To set the Seccomp profile for a Container, include the seccompProfile field in the securityContext section of your Pod or Container manifest. + ## The seccompProfile field is a SeccompProfile object consisting of type and localhostProfile. Valid options for type include RuntimeDefault, Unconfined, and Localhost. + ## localhostProfile must only be set set if type Localhost. It indicates the path of the pre-configured profile on the node, relative to the kubelet's configured Seccomp profile location (configured with the --root-dir flag). + seccompProfile: + type: RuntimeDefault + ## NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ + # nodeSelector: {} + ## A subset of PodSecurityContext. PodSecurityContext holds pod-level security attributes and common container settings + podSecurityContext: + ## A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to + ## change the ownership of that volume to be owned by the pod: + ## + ## 1. The owning GID will be the FSGroup + ## 2. The setgid bit is set (new files created in the volume will be owned by FSGroup)## 3. The permission bits are OR'd with rw-rw---- + ## + ## If unset, the Kubelet will not modify the ownership and permissions of any volume. + fsGroup: 10002 + + ## fsGroupChangePolicy defines behavior of changing ownership and permission of the volume before being exposed inside Pod. + ## This field will only apply to volume types which support fsGroup based ownership(and permissions). + ## It will have no effect on ephemeral volume types such as: secret, configmaps and emptydir. Valid values are "OnRootMismatch" and "Always". If not specified, "Always" is used. + # fsGroupChangePolicy: + + ## The GID to run the entrypoint of the container process. Uses runtime default if unset. + runAsGroup: 10002 + + ## Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. + runAsNonRoot: true + + ## The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. + runAsUser: 10002 + + ## SELinuxOptions are the labels to be applied to all the pod containers + # seLinuxOptions: + ## Level is SELinux level label that applies to the container. + # level: + + ## Role is a SELinux role label that applies to the container. + # role: + + ## Type is a SELinux type label that applies to the container. + # type: + + ## User is a SELinux user label that applies to the container. + # user: + + ## "To set the Seccomp profile for a Container, include the seccompProfile field in the securityContext section of your Pod or Container manifest. + ## The seccompProfile field is a SeccompProfile object consisting of type and localhostProfile. + ## Valid options for type include RuntimeDefault, Unconfined, and Localhost. localhostProfile must only be set set if type Localhost. + ## It indicates the path of the pre-configured profile on the node, relative to the kubelet's configured Seccomp profile location (configured with the --root-dir flag). + # seccompProfile: + # localhostProfile: + # type: + + ## A list of groups applied to the first process run in each container, in addition to the container's primary GID. + ## If unspecified, no groups will be added to any container. + supplementalGroups: [] + ## Kubernetes resources to allocate to each instance. + resources: + ## Requests describes the minimum amount of compute resources required. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + requests: + memory: 50Mi + cpu: 50m + + ## Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + limits: + memory: 50Mi + ## Controls configuration of the ServiceAccount for this component + serviceAccount: + ## Whether a ServiceAccount should be created by the chart or not + create: true + + ## What name to give the ServiceAccount. If not provided the chart will provide the name automatically + name: "" + + ## Annotations to add to the service account + annotations: {} + ## Workload tolerations + ## The pod this Toleration is attached to tolerates any taint that matches the triple using the matching operator . ## - ## 1. The owning GID will be the FSGroup - ## 2. The setgid bit is set (new files created in the volume will be owned by FSGroup)## 3. The permission bits are OR'd with rw-rw---- + ## * effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute. + ## * key is the taint key that the toleration applies to. Empty means match all taint keys. If the key is empty, operator must be Exists; this combination means to match all values and all keys. + ## * operator represents a key's relationship to the value. Valid operators are Exists and Equal. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category. + ## * value is the taint value the toleration matches to. If the operator is Exists, the value should be empty, otherwise just a regular string. ## - ## If unset, the Kubelet will not modify the ownership and permissions of any volume. - fsGroup: 10002 + ## * tolerationSeconds represents the period of time the toleration (which must be of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, it is not set, which means tolerate the taint forever (do not evict). Zero and negative values will be treated as 0 (evict immediately) by the system. + ## e.g. + ## tolerations: + ## - effect: + ## key: + ## operator: + ## value: - ## fsGroupChangePolicy defines behavior of changing ownership and permission of the volume before being exposed inside Pod. - ## This field will only apply to volume types which support fsGroup based ownership(and permissions). - ## It will have no effect on ephemeral volume types such as: secret, configmaps and emptydir. Valid values are "OnRootMismatch" and "Always". If not specified, "Always" is used. - # fsGroupChangePolicy: - - ## The GID to run the entrypoint of the container process. Uses runtime default if unset. - runAsGroup: 10002 - - ## Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. - runAsNonRoot: true - - ## The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. - runAsUser: 10002 - - ## SELinuxOptions are the labels to be applied to all the pod containers - # seLinuxOptions: - ## Level is SELinux level label that applies to the container. - # level: - - ## Role is a SELinux role label that applies to the container. - # role: - - ## Type is a SELinux type label that applies to the container. - # type: - - ## User is a SELinux user label that applies to the container. - # user: - - ## "To set the Seccomp profile for a Container, include the seccompProfile field in the securityContext section of your Pod or Container manifest. - ## The seccompProfile field is a SeccompProfile object consisting of type and localhostProfile. - ## Valid options for type include RuntimeDefault, Unconfined, and Localhost. localhostProfile must only be set set if type Localhost. - ## It indicates the path of the pre-configured profile on the node, relative to the kubelet's configured Seccomp profile location (configured with the --root-dir flag). - # seccompProfile: - # localhostProfile: - # type: - - ## A list of groups applied to the first process run in each container, in addition to the container's primary GID. - ## If unspecified, no groups will be added to any container. - supplementalGroups: [] - - ## Kubernetes resources to allocate to each instance. - resources: - ## Requests describes the minimum amount of compute resources required. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ - requests: - memory: 50Mi - cpu: 50m - - ## Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ - limits: - memory: 50Mi - - ## Controls configuration of the ServiceAccount for this component - serviceAccount: - ## Whether a ServiceAccount should be created by the chart or not - create: true - - ## What name to give the ServiceAccount. If not provided the chart will provide the name automatically - name: "" - - ## Annotations to add to the service account - annotations: {} - - ## Workload tolerations - ## The pod this Toleration is attached to tolerates any taint that matches the triple using the matching operator . - ## - ## * effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute. - ## * key is the taint key that the toleration applies to. Empty means match all taint keys. If the key is empty, operator must be Exists; this combination means to match all values and all keys. - ## * operator represents a key's relationship to the value. Valid operators are Exists and Equal. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category. - ## * value is the taint value the toleration matches to. If the operator is Exists, the value should be empty, otherwise just a regular string. - ## - ## * tolerationSeconds represents the period of time the toleration (which must be of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, it is not set, which means tolerate the taint forever (do not evict). Zero and negative values will be treated as 0 (evict immediately) by the system. - ## e.g. - ## tolerations: - ## - effect: - ## key: - ## operator: - ## value: - - tolerations: [] + tolerations: []