apiVersion: apps/v1
kind: Deployment
metadata:
  name: pagerduty-operator
  namespace: pagerduty-operator
spec:
  replicas: 1
  selector:
    matchLabels:
      name: pagerduty-operator
  template:
    metadata:
      labels:
        name: pagerduty-operator
    spec:
      serviceAccountName: pagerduty-operator
      containers:
        - name: pagerduty-operator
          image: quay.io/app-sre/pagerduty-operator
          command:
          - pagerduty-operator
          imagePullPolicy: Always
          resources:
            requests:
              memory: "400Mi"
              cpu: "100m"
            limits:
              memory: "400Mi"
              cpu: "100m"
          env:
            - name: WATCH_NAMESPACE
              valueFrom:
                fieldRef:
                  fieldPath: metadata.namespace
            - name: POD_NAME
              valueFrom:
                fieldRef:
                  fieldPath: metadata.name
            - name: OPERATOR_NAME
              value: "pagerduty-operator"
