diff --git a/stable/grafana/Chart.yaml b/stable/grafana/Chart.yaml index 48961a30ac29..cf79fb499587 100755 --- a/stable/grafana/Chart.yaml +++ b/stable/grafana/Chart.yaml @@ -1,5 +1,5 @@ name: grafana -version: 0.8.3 +version: 0.8.4 description: The leading tool for querying and visualizing time series and metrics. home: https://grafana.net icon: https://raw.githubusercontent.com/grafana/grafana/master/public/img/logo_transparent_400x.png diff --git a/stable/grafana/templates/deployment.yaml b/stable/grafana/templates/deployment.yaml index c85dd87428cd..9f3799c208ff 100644 --- a/stable/grafana/templates/deployment.yaml +++ b/stable/grafana/templates/deployment.yaml @@ -50,6 +50,19 @@ spec: app: {{ template "grafana.server.fullname" . }} {{- end }} {{- end }} + initContainers: + - name: copy-configs + image: busybox + command: ['sh', '-c', 'cp /tmp/config-volume-configmap/* /tmp/config-volume 2>/dev/null || true; cp /tmp/dashboard-volume-configmap/* /tmp/dashboard-volume 2>/dev/null || true'] + volumeMounts: + - name: config-volume-configmap + mountPath: /tmp/config-volume-configmap + - name: dashboard-volume-configmap + mountPath: /tmp/dashboard-volume-configmap + - name: config-volume + mountPath: /tmp/config-volume + - name: dashboard-volume + mountPath: /tmp/dashboard-volume containers: - name: {{ template "grafana.name" . }} image: "{{ .Values.server.image }}" @@ -92,9 +105,13 @@ spec: terminationGracePeriodSeconds: {{ default 300 .Values.server.terminationGracePeriodSeconds }} volumes: - name: config-volume + emptyDir: {} + - name: dashboard-volume + emptyDir: {} + - name: config-volume-configmap configMap: name: {{ template "grafana.server.fullname" . }}-config - - name: dashboard-volume + - name: dashboard-volume-configmap configMap: name: {{ template "grafana.server.fullname" . }}-dashs - name: storage-volume