apiVersion: apps/v1
kind: Deployment
metadata:
  name: dns-operator
  namespace: openshift-dns-operator
spec:
  replicas: 1
  selector:
    matchLabels:
      name: dns-operator
  template:
    metadata:
      labels:
        name: dns-operator
    spec:
      dnsPolicy: Default
      nodeSelector:
        beta.kubernetes.io/os: linux
        node-role.kubernetes.io/master: ''
      restartPolicy: Always
      priorityClassName: system-cluster-critical
      serviceAccountName: dns-operator
      containers:
        - name: dns-operator
          terminationMessagePolicy: FallbackToLogsOnError
          image: openshift/origin-cluster-dns-operator:latest
          command:
          - dns-operator
          terminationGracePeriodSeconds: 2
          env:
            - name: RELEASE_VERSION
              value: "0.0.1-snapshot"
            - name: IMAGE
              value: openshift/origin-coredns:v4.0
            - name: OPENSHIFT_CLI_IMAGE
              value: openshift/origin-cli:v4.0
          resources:
            requests:
              cpu: 10m
      tolerations:
      - key: "node-role.kubernetes.io/master"
        operator: "Exists"
        effect: "NoSchedule"
      - key: "node.kubernetes.io/unreachable"
        operator: "Exists"
        effect: "NoExecute"
        tolerationSeconds: 120
      - key: "node.kubernetes.io/not-ready"
        operator: "Exists"
        effect: "NoExecute"
      - key: "node.kubernetes.io/not-ready"
        operator: "Exists"
        effect: "NoSchedule"
