apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app: whitetail
    service: whitetail
  name: whitetail
spec:
  selector:
    matchLabels:
      app: whitetail
      service: whitetail
  template:
    metadata:
      labels:
        app: whitetail
        service: whitetail
      name: whitetail
    spec:
      containers:
      - image: johncarterodg/whitetail:0.9
        imagePullPolicy: Always
        name: whitetail
        ports:
        - containerPort: 9001
          name: wt-http
          protocol: TCP
        - containerPort: 9002
          name: wt-tcp
          protocol: TCP
        - containerPort: 9003
          name: wt-udp
          protocol: UDP
        resources:
          limits:
            memory: 2Gi
            cpu: "2"
        stdin: true
        tty: true
        volumeMounts:
        - mountPath: /whitetail/config
          name: whitetail-config-vol
        - mountPath: /whitetail/data
          name: whitetail-persistent-storage
      - image: johncarterodg/ceres-prototype:dev
        imagePullPolicy: Always
        name: ceres
        ports:
        - containerPort: 9090
          name: ceres-http
          protocol: TCP
        resources:
          limits:
            memory: 1Gi
            cpu: "1"
        stdin: true
        tty: true
        volumeMounts:
        - mountPath: /ceres/ceres_home/config
          name: ceres-config-vol
        - mountPath: /ceres/ceres_home
          name: ceres-persistent-storage
      hostname: whitetail
      restartPolicy: Always
      securityContext:
        runAsUser: 0
      volumes:
      - configMap:
          name: whitetail-config-configmap
        name: whitetail-config-vol
      - name: whitetail-persistent-storage
        persistentVolumeClaim:
          claimName: whitetail-pvc
      - configMap:
          name: ceres-config-configmap
        name: ceres-config-vol
      - name: ceres-persistent-storage
        persistentVolumeClaim:
          claimName: ceres-pvc