]> piware.de Git - learn-metrics.git/commitdiff
Move Grafana config to directory volume
authorMartin Pitt <martin@piware.de>
Wed, 16 Jun 2021 05:23:14 +0000 (07:23 +0200)
committerMartin Pitt <martin@piware.de>
Wed, 16 Jun 2021 06:02:56 +0000 (08:02 +0200)
This more closely resembles what one would do on Kubernetes with a
`ConfigMap`.

learn-metrics.yaml

index 38cc24e09b1bf03e46695ec7962a613c55d0698e..7c1c7ea563403d001bfec83d51e3b165bb50c801 100644 (file)
@@ -11,13 +11,15 @@ spec:
     env:
     - name: GF_SECURITY_ADMIN_PASSWORD
       value: foobar
+    - name: GF_PATHS_CONFIG
+      value: /grafana-config/grafana.ini
     ports:
     - containerPort: 3000
       hostPort: 3000
       protocol: TCP
     volumeMounts:
     - name: grafana-config
-      mountPath: /opt/bitnami/grafana/conf/grafana.ini
+      mountPath: /grafana-config
       readOnly: true
     - name: grafana-datasource
       mountPath: /etc/grafana/provisioning/datasources/datasource.yaml
@@ -47,8 +49,7 @@ spec:
       type: File
     name: grafana-datasource
   - hostPath:
-      path: ./conf-grafana/grafana.ini
-      type: File
+      path: ./conf-grafana
     name: grafana-config
   - hostPath:
       path: ./conf-prometheus