diff --git a/charts/hono/Chart.yaml b/charts/hono/Chart.yaml index 04f2deb3..d2d89b9b 100755 --- a/charts/hono/Chart.yaml +++ b/charts/hono/Chart.yaml @@ -15,7 +15,7 @@ name: hono description: | Eclipse Hono™ provides remote service interfaces for connecting large numbers of IoT devices to a back end and interacting with them in a uniform way regardless of the device communication protocol. -version: 1.9.13 +version: 1.9.14 # Version of Hono being deployed by the chart appVersion: 1.9.1 keywords: diff --git a/charts/hono/templates/_helpers.tpl b/charts/hono/templates/_helpers.tpl index 70aa75c9..5721df48 100644 --- a/charts/hono/templates/_helpers.tpl +++ b/charts/hono/templates/_helpers.tpl @@ -423,6 +423,21 @@ The scope passed in is expected to be a dict with keys {{- end }} {{- end }} +{{/* +Adds environment variables from a given configmap +to a component's container. + +The scope passed in is expected to be a dict with keys +- (mandatory) "dot": the root scope (".") +- (mandatory) "componentConfig": the component's configuration properties from the values.yaml file +*/}} +{{- define "hono.component.envConfigMap" }} +{{- if .componentConfig.envConfigMap }} +envFrom: +- configMapRef: + name: {{ .componentConfig.envConfigMap }} +{{- end }} +{{- end }} {{/* Add Quarkus related configuration properties to YAML file. diff --git a/charts/hono/templates/hono-adapter-amqp/hono-adapter-amqp-vertx-deployment.yaml b/charts/hono/templates/hono-adapter-amqp/hono-adapter-amqp-vertx-deployment.yaml index 9bcb42f2..027dfe47 100644 --- a/charts/hono/templates/hono-adapter-amqp/hono-adapter-amqp-vertx-deployment.yaml +++ b/charts/hono/templates/hono-adapter-amqp/hono-adapter-amqp-vertx-deployment.yaml @@ -51,6 +51,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} volumeMounts: {{- include "hono.container.secretVolumeMounts" $args | indent 8 }} {{- with .Values.adapters.amqp.resources }} diff --git a/charts/hono/templates/hono-adapter-coap/hono-adapter-coap-vertx-deployment.yaml b/charts/hono/templates/hono-adapter-coap/hono-adapter-coap-vertx-deployment.yaml index a92965c3..ff747dd0 100644 --- a/charts/hono/templates/hono-adapter-coap/hono-adapter-coap-vertx-deployment.yaml +++ b/charts/hono/templates/hono-adapter-coap/hono-adapter-coap-vertx-deployment.yaml @@ -51,6 +51,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} volumeMounts: {{- include "hono.container.secretVolumeMounts" $args | indent 8 }} {{- with .Values.adapters.coap.resources }} diff --git a/charts/hono/templates/hono-adapter-http/hono-adapter-http-vertx-deployment.yaml b/charts/hono/templates/hono-adapter-http/hono-adapter-http-vertx-deployment.yaml index b4910e2f..233e06aa 100644 --- a/charts/hono/templates/hono-adapter-http/hono-adapter-http-vertx-deployment.yaml +++ b/charts/hono/templates/hono-adapter-http/hono-adapter-http-vertx-deployment.yaml @@ -51,6 +51,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} volumeMounts: {{- include "hono.container.secretVolumeMounts" $args | indent 8 }} {{- with .Values.adapters.http.resources }} diff --git a/charts/hono/templates/hono-adapter-kura/hono-adapter-kura-deployment.yaml b/charts/hono/templates/hono-adapter-kura/hono-adapter-kura-deployment.yaml index 5c55c712..4a4b48d5 100644 --- a/charts/hono/templates/hono-adapter-kura/hono-adapter-kura-deployment.yaml +++ b/charts/hono/templates/hono-adapter-kura/hono-adapter-kura-deployment.yaml @@ -51,6 +51,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} volumeMounts: {{- include "hono.container.secretVolumeMounts" $args | indent 8 }} {{- with .Values.adapters.kura.resources }} diff --git a/charts/hono/templates/hono-adapter-lora/hono-adapter-lora-vertx-deployment.yaml b/charts/hono/templates/hono-adapter-lora/hono-adapter-lora-vertx-deployment.yaml index a7bbbff6..1a4f8f40 100644 --- a/charts/hono/templates/hono-adapter-lora/hono-adapter-lora-vertx-deployment.yaml +++ b/charts/hono/templates/hono-adapter-lora/hono-adapter-lora-vertx-deployment.yaml @@ -51,6 +51,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} volumeMounts: {{- include "hono.container.secretVolumeMounts" $args | indent 8 }} {{- with .Values.adapters.lora.resources }} diff --git a/charts/hono/templates/hono-adapter-mqtt/hono-adapter-mqtt-vertx-deployment.yaml b/charts/hono/templates/hono-adapter-mqtt/hono-adapter-mqtt-vertx-deployment.yaml index 61f16022..518a0085 100644 --- a/charts/hono/templates/hono-adapter-mqtt/hono-adapter-mqtt-vertx-deployment.yaml +++ b/charts/hono/templates/hono-adapter-mqtt/hono-adapter-mqtt-vertx-deployment.yaml @@ -51,6 +51,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} volumeMounts: {{- include "hono.container.secretVolumeMounts" $args | indent 8 }} {{- with .Values.adapters.mqtt.resources }} diff --git a/charts/hono/templates/hono-service-auth/hono-service-auth-deployment.yaml b/charts/hono/templates/hono-service-auth/hono-service-auth-deployment.yaml index 2901606a..470eda40 100644 --- a/charts/hono/templates/hono-service-auth/hono-service-auth-deployment.yaml +++ b/charts/hono/templates/hono-service-auth/hono-service-auth-deployment.yaml @@ -48,6 +48,7 @@ spec: fieldRef: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} volumeMounts: {{- include "hono.container.secretVolumeMounts" $args | indent 8 }} {{- with .Values.authServer.resources }} diff --git a/charts/hono/templates/hono-service-command-router/hono-service-command-router-deployment.yaml b/charts/hono/templates/hono-service-command-router/hono-service-command-router-deployment.yaml index 7cb3bf78..07ea60a3 100644 --- a/charts/hono/templates/hono-service-command-router/hono-service-command-router-deployment.yaml +++ b/charts/hono/templates/hono-service-command-router/hono-service-command-router-deployment.yaml @@ -51,6 +51,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} volumeMounts: {{- include "hono.container.secretVolumeMounts" $args | indent 8 }} {{- if not ( or .Values.dataGridSpec .Values.dataGridExample.enabled ) }} diff --git a/charts/hono/templates/hono-service-device-connection/hono-service-device-connection-deployment.yaml b/charts/hono/templates/hono-service-device-connection/hono-service-device-connection-deployment.yaml index bb3a9392..21707a59 100644 --- a/charts/hono/templates/hono-service-device-connection/hono-service-device-connection-deployment.yaml +++ b/charts/hono/templates/hono-service-device-connection/hono-service-device-connection-deployment.yaml @@ -51,6 +51,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" ( merge $args ( dict "additionalProfile" ( ( or .Values.dataGridSpec ( or .Values.deviceConnectionService.hono.deviceConnection.remote .Values.dataGridExample.enabled ) ) | ternary "" "embedded-cache" ) ) ) | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} volumeMounts: {{- include "hono.container.secretVolumeMounts" $args | indent 8 }} {{- with .Values.deviceConnectionService.resources }} diff --git a/charts/hono/templates/hono-service-device-registry-embedded/hono-service-device-registry-statefulset.yaml b/charts/hono/templates/hono-service-device-registry-embedded/hono-service-device-registry-statefulset.yaml index b4f0eede..8d0c6c35 100644 --- a/charts/hono/templates/hono-service-device-registry-embedded/hono-service-device-registry-statefulset.yaml +++ b/charts/hono/templates/hono-service-device-registry-embedded/hono-service-device-registry-statefulset.yaml @@ -56,6 +56,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} securityContext: privileged: false volumeMounts: diff --git a/charts/hono/templates/hono-service-device-registry-file/hono-service-device-registry-statefulset.yaml b/charts/hono/templates/hono-service-device-registry-file/hono-service-device-registry-statefulset.yaml index feeb70b2..52429de7 100644 --- a/charts/hono/templates/hono-service-device-registry-file/hono-service-device-registry-statefulset.yaml +++ b/charts/hono/templates/hono-service-device-registry-file/hono-service-device-registry-statefulset.yaml @@ -56,6 +56,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} securityContext: privileged: false volumeMounts: diff --git a/charts/hono/templates/hono-service-device-registry-jdbc/hono-service-device-registry-deployment.yaml b/charts/hono/templates/hono-service-device-registry-jdbc/hono-service-device-registry-deployment.yaml index cce450e7..19408e9a 100644 --- a/charts/hono/templates/hono-service-device-registry-jdbc/hono-service-device-registry-deployment.yaml +++ b/charts/hono/templates/hono-service-device-registry-jdbc/hono-service-device-registry-deployment.yaml @@ -53,6 +53,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} securityContext: privileged: false volumeMounts: diff --git a/charts/hono/templates/hono-service-device-registry-mongodb/hono-service-device-registry-deployment.yaml b/charts/hono/templates/hono-service-device-registry-mongodb/hono-service-device-registry-deployment.yaml index cb13bf7c..88393307 100644 --- a/charts/hono/templates/hono-service-device-registry-mongodb/hono-service-device-registry-deployment.yaml +++ b/charts/hono/templates/hono-service-device-registry-mongodb/hono-service-device-registry-deployment.yaml @@ -53,6 +53,7 @@ spec: fieldPath: metadata.namespace {{- include "hono.component.springEnv" $args | indent 8 }} {{- include "hono.jaeger.clientConf" $args | indent 8 }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} securityContext: privileged: false volumeMounts: diff --git a/charts/hono/templates/jaeger/jaeger-deployment.yaml b/charts/hono/templates/jaeger/jaeger-deployment.yaml index baa85f59..dabf20d0 100644 --- a/charts/hono/templates/jaeger/jaeger-deployment.yaml +++ b/charts/hono/templates/jaeger/jaeger-deployment.yaml @@ -60,6 +60,7 @@ spec: volumeMounts: {{- include "hono.container.secretVolumeMounts" $args | indent 8 }} {{- with .Values.jaegerBackendExample.resources }} + {{- include "hono.component.envConfigMap" $args | indent 8 }} resources: {{- . | toYaml | nindent 10 }} {{- end }} diff --git a/charts/hono/values.yaml b/charts/hono/values.yaml index 84dec1b5..ada336a6 100755 --- a/charts/hono/values.yaml +++ b/charts/hono/values.yaml @@ -284,6 +284,9 @@ jaegerBackendExample: # secretName: "other-stuff" # mountPath: "/etc/other" + # The configMap to get additional environment variables from for this deploy. + envConfigMap: + # jaegerAgentImage contains the name (including tag) # of the container image to use for the Jaeger Agent sidecar deployed # with Hono's components. @@ -546,6 +549,9 @@ adapters: # secretName: "other-stuff" # mountPath: "/etc/other" + # The configMap to get additional environment variabes from for this adapter. + envConfigMap: + # hono contains the adapter's configuration properties as defined in # https://www.eclipse.org/hono/docs/admin-guide/amqp-adapter-config/ hono: @@ -640,6 +646,9 @@ adapters: # secretName: "other-stuff" # mountPath: "/etc/other" + # The configMap to get additional environment variabes from for this adapter. + envConfigMap: + # hono contains the adapter's configuration properties hono: app: @@ -725,6 +734,9 @@ adapters: # secretName: "other-stuff" # mountPath: "/etc/other" + # The configMap to get additional environment variabes from for this adapter. + envConfigMap: + # hono contains the adapter's configuration properties as defined in # https://www.eclipse.org/hono/docs/admin-guide/http-adapter-config/ hono: @@ -819,6 +831,9 @@ adapters: # secretName: "other-stuff" # mountPath: "/etc/other" + # The configMap to get additional environment variabes from for this adapter. + envConfigMap: + # hono contains the adapter's configuration properties as defined in # https://www.eclipse.org/hono/docs/admin-guide/kura-adapter-config/ hono: @@ -913,6 +928,9 @@ adapters: # secretName: "other-stuff" # mountPath: "/etc/other" + # The configMap to get additional environment variabes from for this adapter. + envConfigMap: + # hono contains the adapter's configuration properties hono: app: @@ -1006,6 +1024,9 @@ adapters: # secretName: "other-stuff" # mountPath: "/etc/other" + # The configMap to get additional environment variabes from for this adapter. + envConfigMap: + # hono contains the adapter's configuration properties as defined in # https://www.eclipse.org/hono/docs/admin-guide/mqtt-adapter-config/ hono: @@ -1094,6 +1115,9 @@ authServer: # secretName: "other-stuff" # mountPath: "/etc/other" + # The configMap to get additional environment variabes from for this auth server. + envConfigMap: + # hono contains the Auth Server's configuration properties as defined in # https://www.eclipse.org/hono/docs/admin-guide/auth-server-config/ hono: @@ -1264,6 +1288,9 @@ deviceRegistryExample: # for a description of the properties' semantics. resources: + # The configMap to get additional environment variabes from for this device registry. + envConfigMap: + # embeddedJdbcDeviceRegistry contains configuration properties specific to the # embedded JDBC device registry. embeddedJdbcDeviceRegistry: @@ -1305,6 +1332,9 @@ deviceRegistryExample: cpu: "1" memory: "500Mi" + # The configMap to get additional environment variabes from for this device registry. + envConfigMap: + # mongoDBBasedDeviceRegistry contains configuration properties specific to the # MongoDB based device registry. mongoDBBasedDeviceRegistry: @@ -1348,6 +1378,9 @@ deviceRegistryExample: # The password to use for authenticating to the MongoDB instance. # password: + # The configMap to get additional environment variabes from for this device registry. + envConfigMap: + # jdbcBasedDeviceRegistry contains configuration properties specific to the # jdbc based device registry. jdbcBasedDeviceRegistry: @@ -1378,6 +1411,10 @@ deviceRegistryExample: resources: # registry.jdbc contains the configuration properties for device registry # to connect to the database. + + # The configMap to get additional environment variabes from for this device registry. + envConfigMap: + registry: jdbc: # the jdbc properties for read-only operations @@ -1538,6 +1575,9 @@ deviceConnectionService: # secretName: "key-material" # mountPath: "/etc/tls" + # The configMap to get additional environment variabes from for this device connection service. + envConfigMap: + # hono contains the service's configuration properties as defined in # https://www.eclipse.org/hono/docs/admin-guide/device-connection-config/ hono: @@ -1658,6 +1698,9 @@ commandRouterService: # secretName: "key-material" # mountPath: "/etc/tls" + # The configMap to get additional environment variabes from for this command router service. + envConfigMap: + # hono contains the service's configuration properties as defined in # https://www.eclipse.org/hono/docs/admin-guide/command-router-config/ hono: