Skip to content

Commit

Permalink
Merge pull request #179 from ravilr/extra_envs
Browse files Browse the repository at this point in the history
Support extraEnv value setting for all flux controllers
  • Loading branch information
stefanprodan authored Jul 27, 2023
2 parents 7df8107 + 2b2b321 commit 13a96ef
Show file tree
Hide file tree
Showing 16 changed files with 37 additions and 12 deletions.
4 changes: 2 additions & 2 deletions charts/flux2/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
annotations:
artifacthub.io/changes: |
- "[Chore]: Update App Version to upstream 2.0.0"
- "[Added]: Support extraEnv value setting for all flux controllers"
apiVersion: v2
appVersion: 2.0.0
description: A Helm chart for flux2
name: flux2
sources:
- https://github.com/fluxcd-community/helm-charts
type: application
version: 2.9.0
version: 2.9.1
7 changes: 6 additions & 1 deletion charts/flux2/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# flux2

![Version: 2.9.0](https://img.shields.io/badge/Version-2.9.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.0.0](https://img.shields.io/badge/AppVersion-2.0.0-informational?style=flat-square)
![Version: 2.9.1](https://img.shields.io/badge/Version-2.9.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.0.0](https://img.shields.io/badge/AppVersion-2.0.0-informational?style=flat-square)

A Helm chart for flux2

Expand Down Expand Up @@ -28,6 +28,7 @@ This helm chart is maintain and released by the fluxcd-community on a best effor
| helmController.annotations."prometheus.io/scrape" | string | `"true"` | |
| helmController.container.additionalArgs | list | `[]` | |
| helmController.create | bool | `true` | |
| helmController.extraEnv | list | `[]` | |
| helmController.image | string | `"ghcr.io/fluxcd/helm-controller"` | |
| helmController.imagePullPolicy | object | `{}` | |
| helmController.labels | object | `{}` | |
Expand All @@ -46,6 +47,7 @@ This helm chart is maintain and released by the fluxcd-community on a best effor
| imageAutomationController.annotations."prometheus.io/scrape" | string | `"true"` | |
| imageAutomationController.container.additionalArgs | list | `[]` | |
| imageAutomationController.create | bool | `true` | |
| imageAutomationController.extraEnv | list | `[]` | |
| imageAutomationController.image | string | `"ghcr.io/fluxcd/image-automation-controller"` | |
| imageAutomationController.imagePullPolicy | object | `{}` | |
| imageAutomationController.labels | object | `{}` | |
Expand All @@ -65,6 +67,7 @@ This helm chart is maintain and released by the fluxcd-community on a best effor
| imageReflectionController.annotations."prometheus.io/scrape" | string | `"true"` | |
| imageReflectionController.container.additionalArgs | list | `[]` | |
| imageReflectionController.create | bool | `true` | |
| imageReflectionController.extraEnv | list | `[]` | |
| imageReflectionController.image | string | `"ghcr.io/fluxcd/image-reflector-controller"` | |
| imageReflectionController.imagePullPolicy | object | `{}` | |
| imageReflectionController.labels | object | `{}` | |
Expand All @@ -85,6 +88,7 @@ This helm chart is maintain and released by the fluxcd-community on a best effor
| kustomizeController.container.additionalArgs | list | `[]` | |
| kustomizeController.create | bool | `true` | |
| kustomizeController.envFrom | object | `{"map":{"name":""},"secret":{"name":""}}` | Defines envFrom using a configmap and/or secret. |
| kustomizeController.extraEnv | list | `[]` | |
| kustomizeController.extraSecretMounts | list | `[]` | Defines additional mounts with secrets. Secrets must be manually created in the namespace or with kustomizeController.secret |
| kustomizeController.image | string | `"ghcr.io/fluxcd/kustomize-controller"` | |
| kustomizeController.imagePullPolicy | object | `{}` | |
Expand All @@ -111,6 +115,7 @@ This helm chart is maintain and released by the fluxcd-community on a best effor
| notificationController.annotations."prometheus.io/scrape" | string | `"true"` | |
| notificationController.container.additionalArgs | list | `[]` | |
| notificationController.create | bool | `true` | |
| notificationController.extraEnv | list | `[]` | |
| notificationController.image | string | `"ghcr.io/fluxcd/notification-controller"` | |
| notificationController.imagePullPolicy | object | `{}` | |
| notificationController.labels | object | `{}` | |
Expand Down
3 changes: 3 additions & 0 deletions charts/flux2/templates/helm-controller.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.namespace
{{- with .Values.helmController.extraEnv }}
{{- toYaml . | nindent 8 }}
{{- end }}
image: {{ template "template.image" .Values.helmController }}
{{- if .Values.helmController.imagePullPolicy }}
imagePullPolicy: {{ .Values.helmController.imagePullPolicy }}
Expand Down
3 changes: 3 additions & 0 deletions charts/flux2/templates/image-automation-controller.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.namespace
{{- with .Values.imageAutomationController.extraEnv }}
{{- toYaml . | nindent 8 }}
{{- end }}
image: {{ template "template.image" .Values.imageAutomationController }}
{{- if .Values.imageAutomationController.imagePullPolicy }}
imagePullPolicy: {{ .Values.imageAutomationController.imagePullPolicy }}
Expand Down
3 changes: 3 additions & 0 deletions charts/flux2/templates/image-reflector-controller.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.namespace
{{- with .Values.imageReflectionController.extraEnv }}
{{- toYaml . | nindent 8 }}
{{- end }}
image: {{ template "template.image" .Values.imageReflectionController }}
{{- if .Values.imageReflectionController.imagePullPolicy }}
imagePullPolicy: {{ .Values.imageReflectionController.imagePullPolicy }}
Expand Down
3 changes: 3 additions & 0 deletions charts/flux2/templates/kustomize-controller.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.namespace
{{- with .Values.kustomizeController.extraEnv }}
{{- toYaml . | nindent 8 }}
{{- end }}
{{- if or (.Values.kustomizeController.envFrom.map.name) (.Values.kustomizeController.envFrom.secret.name) }}
envFrom:
{{- if .Values.kustomizeController.envFrom.map.name }}
Expand Down
3 changes: 3 additions & 0 deletions charts/flux2/templates/notification-controller.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.namespace
{{- with .Values.notificationController.extraEnv }}
{{- toYaml . | nindent 8 }}
{{- end }}
image: {{ template "template.image" .Values.notificationController }}
{{- if .Values.notificationController.imagePullPolicy }}
imagePullPolicy: {{ .Values.notificationController.imagePullPolicy }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ should match snapshot of default values:
app.kubernetes.io/part-of: flux
app.kubernetes.io/version: 2.0.0
control-plane: controller
helm.sh/chart: flux2-2.9.0
helm.sh/chart: flux2-2.9.1
name: helm-controller
spec:
replicas: 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ should match snapshot of default values:
app.kubernetes.io/part-of: flux
app.kubernetes.io/version: 2.0.0
control-plane: controller
helm.sh/chart: flux2-2.9.0
helm.sh/chart: flux2-2.9.1
name: image-automation-controller
spec:
replicas: 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ should match snapshot of default values:
app.kubernetes.io/part-of: flux
app.kubernetes.io/version: 2.0.0
control-plane: controller
helm.sh/chart: flux2-2.9.0
helm.sh/chart: flux2-2.9.1
name: image-reflector-controller
spec:
replicas: 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ should match snapshot of default values:
app.kubernetes.io/managed-by: Helm
app.kubernetes.io/part-of: flux
app.kubernetes.io/version: 2.0.0
helm.sh/chart: flux2-2.9.0
helm.sh/chart: flux2-2.9.1
name: test1
namespace: NAMESPACE
type: Opaque
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ should match snapshot of default values:
app.kubernetes.io/part-of: flux
app.kubernetes.io/version: 2.0.0
control-plane: controller
helm.sh/chart: flux2-2.9.0
helm.sh/chart: flux2-2.9.1
name: kustomize-controller
spec:
replicas: 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ should match snapshot of default values:
app.kubernetes.io/part-of: flux
app.kubernetes.io/version: 2.0.0
control-plane: controller
helm.sh/chart: flux2-2.9.0
helm.sh/chart: flux2-2.9.1
name: notification-controller
spec:
replicas: 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ should match snapshot of default values:
app.kubernetes.io/managed-by: Helm
app.kubernetes.io/part-of: flux
app.kubernetes.io/version: 2.0.0
helm.sh/chart: flux2-2.9.0
helm.sh/chart: flux2-2.9.1
name: RELEASE-NAME-flux-check
spec:
backoffLimit: 1
Expand All @@ -23,7 +23,7 @@ should match snapshot of default values:
app.kubernetes.io/managed-by: Helm
app.kubernetes.io/part-of: flux
app.kubernetes.io/version: 2.0.0
helm.sh/chart: flux2-2.9.0
helm.sh/chart: flux2-2.9.1
name: RELEASE-NAME
spec:
automountServiceAccountToken: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ should match snapshot of default values:
app.kubernetes.io/part-of: flux
app.kubernetes.io/version: 2.0.0
control-plane: controller
helm.sh/chart: flux2-2.9.0
helm.sh/chart: flux2-2.9.1
name: source-controller
spec:
replicas: 1
Expand Down
5 changes: 5 additions & 0 deletions charts/flux2/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ helmController:
labels: {}
container:
additionalArgs: []
extraEnv: []
serviceAccount:
create: true
automount: true
Expand Down Expand Up @@ -95,6 +96,7 @@ imageAutomationController:
labels: {}
container:
additionalArgs: []
extraEnv: []
serviceAccount:
create: true
automount: true
Expand Down Expand Up @@ -122,6 +124,7 @@ imageReflectionController:
labels: {}
container:
additionalArgs: []
extraEnv: []
serviceAccount:
create: true
automount: true
Expand Down Expand Up @@ -149,6 +152,7 @@ kustomizeController:
labels: {}
container:
additionalArgs: []
extraEnv: []
serviceAccount:
create: true
automount: true
Expand Down Expand Up @@ -196,6 +200,7 @@ notificationController:
labels: {}
container:
additionalArgs: []
extraEnv: []
serviceAccount:
create: true
automount: true
Expand Down

0 comments on commit 13a96ef

Please sign in to comment.