Browse Source

chore(helm): add volumes and volumeMounts chart values (#4714)

Jordan JEAN 3 years ago
parent
commit
8d420759f8
3 changed files with 14 additions and 0 deletions
  1. 2 0
      dev/helm/README.md
  2. 8 0
      dev/helm/templates/deployment.yaml
  3. 4 0
      dev/helm/values.yaml

+ 2 - 0
dev/helm/README.md

@@ -104,6 +104,8 @@ The following table lists the configurable parameters of the Wiki.js chart and t
 | `affinity`                       | Affinity settings for wiki.js pod assignment    | `{}`                                                       |
 | `schedulerName`                  | Name of an alternate scheduler for wiki.js pod  | `nil`                                                      |
 | `tolerations`                    | Toleration labels for wiki.jsk pod assignment    | `[]`                                                       |
+| `volumeMounts`                   | Volume mounts for Wiki.js container              | `[]`                                                       |
+| `volumes`                        | Volumes for Wiki.js Pod                          | `[]`                                                       |
 | `ingress.enabled`                    | Enable ingress controller resource          | `false`                                                    |
 | `ingress.annotations`                | Ingress annotations                         | `{}`                                                       |
 | `ingress.hosts`                      | List of ingress rules                        | `[{"host": "wiki.local", "paths": ["/"]}]`                |

+ 8 - 0
dev/helm/templates/deployment.yaml

@@ -63,6 +63,10 @@ spec:
                   key: {{ template "wiki.postgresql.secretKey" . }}
             - name: HA_ACTIVE
               value: {{ .Values.replicaCount | int | le 2 | quote }}
+    {{- with .Values.volumeMounts }}
+          volumeMounts:
+            {{- toYaml . | nindent 12 }}
+    {{- end }}
           ports:
             - name: http
               containerPort: 3000
@@ -85,3 +89,7 @@ spec:
       tolerations:
         {{- toYaml . | nindent 8 }}
     {{- end }}
+    {{- with .Values.volumes }}
+      volumes:
+        {{- toYaml . | nindent 8 }}
+    {{- end }}

+ 4 - 0
dev/helm/values.yaml

@@ -85,6 +85,10 @@ tolerations: []
 
 affinity: {}
 
+volumeMounts: []
+
+volumes: []
+
 # This will allow us to install locales even without internet access using a initContainer & wikjs "sideloading"
 sideload:
   enabled: false