apiVersion: apps/v1
kind: Deployment
metadata:
  name: inferator
spec:
  replicas: 1
  selector:
    matchLabels:
      name: inferator
  strategy:
    rollingUpdate:
      maxSurge: 1
      maxUnavailable: 1
    type: RollingUpdate
  template:
    metadata:
      labels:
        name: inferator
    spec:
      containers:
      - command:
        - inferator
        env:
        - name: OPERATOR_NAME
          valueFrom:
            fieldRef:
              fieldPath: metadata.labels['name']
        - name: POD_NAME
          valueFrom:
            fieldRef:
              fieldPath: metadata.name
        - name: WATCH_NAMESPACE
          valueFrom:
            fieldRef:
              fieldPath: metadata.annotations['olm.targetNamespaces']
        - name: OPERATOR_GROUP
          valueFrom:
            fieldRef:
              fieldPath: metadata.annotations['olm.operatorGroup']
        image: quay.io/tchughesiv/inferator:0.0.2
        imagePullPolicy: Always
        name: inferator
        resources: {}
      serviceAccountName: inferator
