Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions charts/consumer-app-cleanup-job/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,14 @@ commandLine: {}
env: {}
# MY_ENV_VARIABLE: foo-bar
#
# Downward API values

envValueFrom: {}
# - name: NODE_NAME
# valueFrom:
# fieldRef:
# fieldPath: spec.nodeName

secrets: {}
# MY_SECRET: fo-bar
secretRefs: {}
Expand Down
1 change: 1 addition & 0 deletions charts/consumer-app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ Alternatively, a YAML file that specifies the values for the parameters can be p
| `configurationEnvPrefix` | Prefix for environment variables to use that should be parsed as command line arguments. | `APP` |
| `commandLine` | Map of command line arguments passed to the consumer app. | `{}` |
| `env` | Custom environment variables | `{}` |
| `envValueFrom` | Custom Downward API environment variables | `{}` |
| `secrets` | Custom secret environment variables. Prefix with `configurationEnvPrefix` in order to pass secrets to command line or prefix with `KAFKA_` to pass secrets to Kafka Consumer configuration. E.g., `APP_MY_PARAM` would be passed as `--my-param` and `KAFKA_MAX_POLL_TIMEOUT_MS` would be translated to `max.poll.timeout.ms`. | `{}` |
| `secretRefs` | Inject existing secrets as environment variables. Map key is used as environment variable name. Value consists of secret `name` and `key`. | `{}` |
| `secretFilesRefs` | Mount existing secrets as volumes | `[]` |
Expand Down
7 changes: 7 additions & 0 deletions charts/consumer-app/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,13 @@ commandLine: {}
env: {}
# MY_ENV_VARIABLE: foo-bar

# Downward API values
envValueFrom: {}
# - name: NODE_NAME
# valueFrom:
# fieldRef:
# fieldPath: spec.nodeName

secrets: {}
# MY_SECRET: fo-bar
secretRefs: {}
Expand Down
8 changes: 8 additions & 0 deletions charts/consumerproducer-app-cleanup-job/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,14 @@ commandLine: {}
env: {}
# MY_ENV_VARIABLE: foo-bar
#

# Downward API values
envValueFrom: {}
# - name: NODE_NAME
# valueFrom:
# fieldRef:
# fieldPath: spec.nodeName

secrets: {}
# MY_SECRET: fo-bar
secretRefs: {}
Expand Down
1 change: 1 addition & 0 deletions charts/consumerproducer-app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ Alternatively, a YAML file that specifies the values for the parameters can be p
| `configurationEnvPrefix` | Prefix for environment variables to use that should be parsed as command line arguments. | `APP` |
| `commandLine` | Map of command line arguments passed to the consumerproducer app. | `{}` |
| `env` | Custom environment variables | `{}` |
| `envValueFrom` | Custom Downward API environment variables | `{}` |
| `secrets` | Custom secret environment variables. Prefix with `configurationEnvPrefix` in order to pass secrets to command line or prefix with `KAFKA_` to pass secrets to Kafka Consumer configuration. E.g., `APP_MY_PARAM` would be passed as `--my-param` and `KAFKA_MAX_POLL_TIMEOUT_MS` would be translated to `max.poll.timeout.ms`. | `{}` |
| `secretRefs` | Inject existing secrets as environment variables. Map key is used as environment variable name. Value consists of secret `name` and `key`. | `{}` |
| `secretFilesRefs` | Mount existing secrets as volumes | `[]` |
Expand Down
7 changes: 7 additions & 0 deletions charts/consumerproducer-app/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,13 @@ commandLine: {}
env: {}
# MY_ENV_VARIABLE: foo-bar

# Downward API values
envValueFrom: {}
# - name: NODE_NAME
# valueFrom:
# fieldRef:
# fieldPath: spec.nodeName

secrets: {}
# MY_SECRET: fo-bar
secretRefs: {}
Expand Down
1 change: 1 addition & 0 deletions charts/kafka-app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ Renders a `ConfigMap` for the Prometheus JMX exporter sidecar.
| `configurationEnvPrefix` | Prefix for environment variables to use that should be parsed as command line arguments. | `APP` |
| `commandLine` | Map of command line arguments passed to the streams app. | `{}` |
| `env` | Custom environment variables | `{}` |
| `envValueFrom` | Custom Downward API environment variables | `{}` |
| `secrets` | Custom secret environment variables. Prefix with `configurationEnvPrefix` in order to pass secrets to command line or prefix with `KAFKA_` to pass secrets to Kafka Streams configuration. E.g., `APP_MY_PARAM` would be passed as `--my-param` and `KAFKA_MAX_POLL_TIMEOUT_MS` would be translated to `max.poll.timeout.ms`. | `{}` |
| `secretRefs` | Inject existing secrets as environment variables. Map key is used as environment variable name. Value consists of secret `name` and `key`. | `{}` |
| `secretFilesRefs` | Mount existing secrets as volumes | `[]` |
Expand Down
3 changes: 3 additions & 0 deletions charts/kafka-app/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,9 @@ Includes default annotations and conditionally adds consumerGroup if applicable.
{{- $root := . -}}
- name: ENV_PREFIX
value: {{ .Values.configurationEnvPrefix }}_
{{ if .Values.envValueFrom }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
{{ if .Values.envValueFrom }}
{{- if .Values.envValueFrom }}

{{ toYaml .Values.envValueFrom }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it would be better to have a map like approach here. So name is the key and valueFrom is the value. That way merging multiple value.yaml files is possible which is a pattern we often use

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
{{ toYaml .Values.envValueFrom }}
{{- range $key, $value := .Values.envValueFrom }}
- name: {{ $key | quote }}
valueFrom:
{{ toYaml $value | indent 4 }}
{{- end }}

should do the trick. values should look like this

envValueFrom: {}
#  NODE_NAME:
#    fieldRef:
#      fieldPath: spec.nodeName

{{- end }}
{{- range $key, $value := .Values.kafka.config }}
- name: {{ printf "KAFKA_%s" $key | replace "." "_" | upper | quote }}
value: {{ $value | quote }}
Expand Down
7 changes: 7 additions & 0 deletions charts/producer-app-cleanup-job/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,13 @@ commandLine: {}
env: {}
# MY_ENV_VARIABLE: foo-bar

# Downward API values
envValueFrom: {}
# - name: NODE_NAME
# valueFrom:
# fieldRef:
# fieldPath: spec.nodeName

secrets: {}
# MY_SECRET: fo-bar
secretRefs: {}
Expand Down
1 change: 1 addition & 0 deletions charts/producer-app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ Alternatively, a YAML file that specifies the values for the parameters can be p
| `configurationEnvPrefix` | Prefix for environment variables to use that should be parsed as command line arguments. | `APP` |
| `commandLine` | Map of command line arguments passed to the producer app. | `{}` |
| `env` | Custom environment variables | `{}` |
| `envValueFrom` | Custom Downward API environment variables | `{}` |
| `secrets` | Custom secret environment variables. Prefix with `configurationEnvPrefix` in order to pass secrets to command line or prefix with `KAFKA_` to pass secrets to Kafka Streams configuration. E.g., `APP_MY_PARAM` would be passed as `--my-param` and `KAFKA_MAX_POLL_TIMEOUT_MS` would be translated to `max.poll.timeout.ms`. | `{}` |
| `secretRefs` | Inject existing secrets as environment variables. Map key is used as environment variable name. Value consists of secret `name` and `key`. | `{}` |
| `secretFilesRefs` | Mount existing secrets as volumes | `[]` |
Expand Down
7 changes: 7 additions & 0 deletions charts/producer-app/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,13 @@ commandLine: {}
env: {}
# MY_ENV_VARIABLE: foo-bar

# Downward API values
envValueFrom: {}
# - name: NODE_NAME
# valueFrom:
# fieldRef:
# fieldPath: spec.nodeName

secrets: {}
# MY_SECRET: fo-bar
secretRefs: {}
Expand Down
8 changes: 8 additions & 0 deletions charts/streams-app-cleanup-job/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,14 @@ commandLine: {}
env: {}
# MY_ENV_VARIABLE: foo-bar
#

# Downward API values
envValueFrom: {}
# - name: NODE_NAME
# valueFrom:
# fieldRef:
# fieldPath: spec.nodeName

secrets: {}
# MY_SECRET: fo-bar
secretRefs: {}
Expand Down
1 change: 1 addition & 0 deletions charts/streams-app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ Alternatively, a YAML file that specifies the values for the parameters can be p
| `configurationEnvPrefix` | Prefix for environment variables to use that should be parsed as command line arguments. | `APP` |
| `commandLine` | Map of command line arguments passed to the streams app. | `{}` |
| `env` | Custom environment variables | `{}` |
| `envValueFrom` | Custom Downward API environment variables | `{}` |
| `secrets` | Custom secret environment variables. Prefix with `configurationEnvPrefix` in order to pass secrets to command line or prefix with `KAFKA_` to pass secrets to Kafka Streams configuration. E.g., `APP_MY_PARAM` would be passed as `--my-param` and `KAFKA_MAX_POLL_TIMEOUT_MS` would be translated to `max.poll.timeout.ms`. | `{}` |
| `secretRefs` | Inject existing secrets as environment variables. Map key is used as environment variable name. Value consists of secret `name` and `key`. | `{}` |
| `secretFilesRefs` | Mount existing secrets as volumes | `[]` |
Expand Down
7 changes: 7 additions & 0 deletions charts/streams-app/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,13 @@ commandLine: {}
env: {}
# MY_ENV_VARIABLE: foo-bar

# Downward API values
envValueFrom: {}
# - name: NODE_NAME
# valueFrom:
# fieldRef:
# fieldPath: spec.nodeName

secrets: {}
# MY_SECRET: fo-bar
secretRefs: {}
Expand Down
Loading