Add option to disable specific deployments
[oom.git] / kubernetes / vid / templates / vid-mariadb-deployment.yaml
index 7623674..55ef5da 100644 (file)
@@ -1,3 +1,4 @@
+#{{ if not .Values.disableVidVidMariadb }}
 apiVersion: extensions/v1beta1
 kind: Deployment
 metadata:
@@ -29,6 +30,9 @@ spec:
         - name: MYSQL_ROOT_PASSWORD
           value: LF+tp_1WqgSY
         volumeMounts:
+        - mountPath: /etc/localtime
+          name: localtime
+          readOnly: true
         - mountPath: /var/lib/mysql
           name: vid-mariadb-data
         - mountPath: /docker-entrypoint-initdb.d/vid-pre-init.sql
@@ -43,9 +47,12 @@ spec:
           initialDelaySeconds: 5
           periodSeconds: 10
       volumes:
-        - name: vid-mariadb-data
+        - name: localtime
           hostPath:
-            path: /dockerdata-nfs/{{ .Values.nsPrefix }}/vid/mariadb/data
+            path: /etc/localtime
+        - name: vid-mariadb-data
+          persistentVolumeClaim:
+            claimName: vid-db
         - name: vid-pre-init
           hostPath:
             path: /dockerdata-nfs/{{ .Values.nsPrefix }}/vid/vid/lf_config/vid-pre-init.sql
@@ -54,3 +61,4 @@ spec:
             path: /dockerdata-nfs/{{ .Values.nsPrefix }}/vid/vid/lf_config/vid-my.cnf
       imagePullSecrets:
       - name: "{{ .Values.nsPrefix }}-docker-registry-key"
+#{{ end }}
\ No newline at end of file