apiVersion: apps/v1
kind: Deployment
metadata:
  name: kouplet
spec:
  replicas: 1
  selector:
    matchLabels:
      name: kouplet
  template:
    metadata:
      labels:
        name: kouplet
    spec:
      serviceAccountName: kouplet
      volumes:
      - name: kouplet-vol
        persistentVolumeClaim:
          claimName: kouplet-pvc
      containers:
        - name: kouplet
          # Replace this with the built image name
          image: REPLACE_IMAGE
          volumeMounts:
          - mountPath: "/kouplet-persistence"
            name: kouplet-vol
          command:
          - kouplet
          imagePullPolicy: Always
          env:
            - name: WATCH_NAMESPACE
              valueFrom:
                fieldRef:
                  fieldPath: metadata.namespace
            - name: POD_NAME
              valueFrom:
                fieldRef:
                  fieldPath: metadata.name
            - name: OPERATOR_NAME
              value: "kouplet"
