From b2d107839f0fa2754167a9d3f04144d809f6cbf3 Mon Sep 17 00:00:00 2001 From: Tommy Date: Sat, 16 Dec 2023 15:53:10 +0100 Subject: [PATCH] feat(dispatch) Move secrets to one common var. Cleanup. --- charts/dispatch/Chart.yaml | 2 +- charts/dispatch/templates/core-deployment.yaml | 2 +- charts/dispatch/templates/scheduler-deployment.yaml | 2 +- charts/dispatch/templates/web-deployment.yaml | 2 +- charts/dispatch/values.yaml | 13 ++++--------- 5 files changed, 8 insertions(+), 13 deletions(-) diff --git a/charts/dispatch/Chart.yaml b/charts/dispatch/Chart.yaml index 7349071..30f3144 100644 --- a/charts/dispatch/Chart.yaml +++ b/charts/dispatch/Chart.yaml @@ -1,4 +1,4 @@ apiVersion: v2 name: dispatch description: Netflix Dispatch incident management system -version: 0.2.0 +version: 0.2.1 diff --git a/charts/dispatch/templates/core-deployment.yaml b/charts/dispatch/templates/core-deployment.yaml index 6fde6c7..23ff6e8 100644 --- a/charts/dispatch/templates/core-deployment.yaml +++ b/charts/dispatch/templates/core-deployment.yaml @@ -29,5 +29,5 @@ spec: env: {{ .Values.core.container.env }} envFrom: - secretRef: - name: {{ .Values.core.container.envFrom.secretRef.name }} + name: {{ .Values.envFromSecret }} {{- end }} \ No newline at end of file diff --git a/charts/dispatch/templates/scheduler-deployment.yaml b/charts/dispatch/templates/scheduler-deployment.yaml index 9d27404..2a7c2dc 100644 --- a/charts/dispatch/templates/scheduler-deployment.yaml +++ b/charts/dispatch/templates/scheduler-deployment.yaml @@ -23,5 +23,5 @@ spec: env: {{ .Values.scheduler.container.env }} envFrom: - secretRef: - name: {{ .Values.scheduler.container.envFrom.secretRef.name }} + name: {{ .Values.envFromSecret }} {{- end }} \ No newline at end of file diff --git a/charts/dispatch/templates/web-deployment.yaml b/charts/dispatch/templates/web-deployment.yaml index 0bb1f73..d43b151 100644 --- a/charts/dispatch/templates/web-deployment.yaml +++ b/charts/dispatch/templates/web-deployment.yaml @@ -29,5 +29,5 @@ spec: env: {{ .Values.web.container.env }} envFrom: - secretRef: - name: {{ .Values.web.container.envFrom.secretRef.name }} + name: {{ .Values.envFromSecret }} {{- end }} \ No newline at end of file diff --git a/charts/dispatch/values.yaml b/charts/dispatch/values.yaml index fad74cc..59c14e9 100644 --- a/charts/dispatch/values.yaml +++ b/charts/dispatch/values.yaml @@ -1,3 +1,5 @@ +envFromSecret: dispatch-secret + image: repository: ghcr.io/tommy-skaug/dispatch tag: v20230919 @@ -16,9 +18,7 @@ core: enabled: true container: env: [] - envFrom: - secretRef: - name: dispatch-secret + web: enabled: true @@ -26,9 +26,7 @@ web: port: 8000 command: ["dispatch", "server", "start", "dispatch.main:app", "--host=0.0.0.0"] env: [] - envFrom: - secretRef: - name: dispatch-secret + service: type: ClusterIP port: 80 @@ -38,9 +36,6 @@ scheduler: container: command: ["dispatch", "scheduler", "start"] env: [] - envFrom: - secretRef: - name: dispatch-secret postgres: hostname: "postgres-rw.databases.svc.cluster.local"