kind: Deployment
apiVersion: apps/v1
metadata:
  name: influxdb-deployment
spec:
  replicas: 1
  selector:
    matchLabels:
      app: influxdb
  template:
    metadata:
      labels:
        app: influxdb
    spec:
      volumes:
        - name: influxdb-data
          persistentVolumeClaim:
            claimName: influxdb-data
        - name: influxdb-config
          configMap:
            name: influxdb-config
            defaultMode: 420
      containers:
        - resources: {}
          terminationMessagePath: /dev/termination-log
          name: influxdb
          ports:
            - containerPort: 8086
              protocol: TCP
          imagePullPolicy: IfNotPresent
          volumeMounts:
            - name: influxdb-data
              mountPath: /var/lib/influxdb
            - name: influxdb-config
              readOnly: true
              mountPath: /etc/influxdb/influxdb.conf
              subPath: influxdb.conf
          terminationMessagePolicy: File
          envFrom:
            - secretRef:
                name: influxdb-secrets
          image: 'influxdb:1.7.4'
      restartPolicy: Always
      terminationGracePeriodSeconds: 30
      dnsPolicy: ClusterFirst
      securityContext: {}
      schedulerName: default-scheduler
  strategy:
    type: RollingUpdate
    rollingUpdate:
      maxUnavailable: 25%
      maxSurge: 25%
  minReadySeconds: 5
  revisionHistoryLimit: 10
  progressDeadlineSeconds: 600
