From 6a1e925d3cc14b76f3a9633cbf05dfa2fe5be7d1 Mon Sep 17 00:00:00 2001 From: B3nBeng <91530842+B3nBeng@users.noreply.github.com> Date: Mon, 16 Jan 2023 17:03:25 +0100 Subject: [PATCH] Update deployment.yaml - Add volumeMounts for initContainers - Add option "offline" for wiki container when we want to use sideload (Need to add "offline: $(OFFLINE_ACTIVE)" into /wiki/config.yml for the docker image) --- dev/helm/templates/deployment.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/dev/helm/templates/deployment.yaml b/dev/helm/templates/deployment.yaml index 62f02bc7..c49c6325 100644 --- a/dev/helm/templates/deployment.yaml +++ b/dev/helm/templates/deployment.yaml @@ -32,6 +32,10 @@ spec: command: [ "sh", "-c" ] args: [ "mkdir -p /wiki/data/sideload && git clone --depth=1 {{ .Values.sideload.repoURL }} /wiki/data/sideload/" ] {{- end }} + {{- with .Values.volumeMounts }} + volumeMounts: + {{- toYaml . | nindent 12 }} + {{- end }} containers: - name: {{ .Chart.Name }} securityContext: @@ -71,6 +75,8 @@ spec: {{- end }} - name: HA_ACTIVE value: {{ .Values.replicaCount | int | le 2 | quote }} + - name: OFFLINE_ACTIVE + value: "{{ default "false" .Values.offline }}" {{- with .Values.volumeMounts }} volumeMounts: {{- toYaml . | nindent 12 }}