From c114e015dbd2c696ff1c967a1c949bd0f11f2f04 Mon Sep 17 00:00:00 2001 From: Viktor Farcic Date: Sat, 30 Nov 2019 22:38:10 +0100 Subject: [PATCH] Added dependencies --- charts/go-demo-6/requirements.yaml | 7 +++++++ charts/go-demo-6/templates/deployment.yaml | 2 ++ charts/go-demo-6/values.yaml | 4 ++++ 3 files changed, 13 insertions(+) create mode 100644 charts/go-demo-6/requirements.yaml diff --git a/charts/go-demo-6/requirements.yaml b/charts/go-demo-6/requirements.yaml new file mode 100644 index 000000000..6a136470a --- /dev/null +++ b/charts/go-demo-6/requirements.yaml @@ -0,0 +1,7 @@ +dependencies: +- name: mongodb + alias: go-demo-6-db + version: 5.3.0 + repository: https://kubernetes-charts.storage.googleapis.com + condition: db.enabled + diff --git a/charts/go-demo-6/templates/deployment.yaml b/charts/go-demo-6/templates/deployment.yaml index 66c01e551..0e978a0b4 100755 --- a/charts/go-demo-6/templates/deployment.yaml +++ b/charts/go-demo-6/templates/deployment.yaml @@ -24,6 +24,8 @@ spec: image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" imagePullPolicy: {{ .Values.image.pullPolicy }} env: + - name: DB + value: {{ template "fullname" . }}-db {{- range $pkey, $pval := .Values.env }} - name: {{ $pkey }} value: {{ quote $pval }} diff --git a/charts/go-demo-6/values.yaml b/charts/go-demo-6/values.yaml index a07364796..3ec35d03f 100755 --- a/charts/go-demo-6/values.yaml +++ b/charts/go-demo-6/values.yaml @@ -39,3 +39,7 @@ readinessProbe: periodSeconds: 10 successThreshold: 1 timeoutSeconds: 1 +go-demo-6-db: + replicaSet: + enabled: true +