apiVersion: apps/v1
kind: Deployment
metadata:
  name: grafana-deployment
  namespace: jalapeno
  labels:
    app: grafana
spec:
  replicas: 1
  selector:
    matchLabels:
      app: grafana
  template:
    metadata:
      labels:
        app: grafana
    spec:
      containers:
      - name: grafana
        image: grafana/grafana:6.6.1
        command:
        - grafana-server
        args:
        - '--homepath=/usr/share/grafana'
        - '--config=/etc/grafana/grafana.ini'
        ports:
        - containerPort: 3000
        volumeMounts:
        - mountPath: /etc/grafana
          name: grafana-config
        - mountPath: /var/log/grafana
          name: grafana-log
        - mountPath: /var/lib/grafana
          name: grafana-lib
      volumes:
      - name: grafana-config
        configMap:
          defaultMode: 420
          name: grafana-config
      - name: grafana-log
        emptyDir: {}
      - name: grafana-lib
        emptyDir: {}
