apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app.kubernetes.io/component: controller
    app.kubernetes.io/name: prometheus-operator
    app.kubernetes.io/version: v0.38.1
  name: prometheus-operator
spec:
  replicas: 1
  selector:
    matchLabels:
      app.kubernetes.io/component: controller
      app.kubernetes.io/name: prometheus-operator
  template:
    metadata:
      labels:
        app.kubernetes.io/component: controller
        app.kubernetes.io/name: prometheus-operator
        app.kubernetes.io/version: v0.38.1
    spec:
      containers:
        - image: redhat-marketplace-authcheck:latest
          imagePullPolicy: IfNotPresent
          name: authcheck
          resources:
            requests:
              cpu: 10m
              memory: 20Mi
          terminationMessagePolicy: FallbackToLogsOnError
        - args:
            - --kubelet-service=kube-system/kubelet
            - --logtostderr=true
            - --config-reloader-image={{CONFIGMAP_RELOADER_IMAGE}}
            - --prometheus-config-reloader={{PROM_CONFIGMAP_RELOADER_IMAGE}}
            - --namespaces={{NAMESPACES}}
            - --prometheus-instance-namespaces={{NAMESPACE}}
            - --alertmanager-instance-namespaces={{NAMESPACE}}
            - --manage-crds=false
          image: registry.redhat.io/openshift4/ose-prometheus-operator:latest
          imagePullPolicy: IfNotPresent
          name: prometheus-operator
          ports:
            - containerPort: 8080
              name: http
          resources:
            requests:
              cpu: 5m
              memory: 60Mi
          securityContext: {}
          terminationMessagePolicy: FallbackToLogsOnError
          volumeMounts:
            - mountPath: /etc/tls/private
              name: prometheus-operator-tls
              readOnly: false
        - args:
            - --logtostderr
            - --secure-listen-address=:8443
            - --tls-cipher-suites=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_RSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256
            - --upstream=https://prometheus-operator.{{NAMESPACE}}.svc:8080/
            - --tls-cert-file=/etc/tls/private/tls.crt
            - --tls-private-key-file=/etc/tls/private/tls.key
          image: registry.redhat.io/openshift4/ose-kube-rbac-proxy:latest
          imagePullPolicy: IfNotPresent
          name: kube-rbac-proxy
          ports:
            - containerPort: 8443
              name: https
          resources:
            requests:
              cpu: 1m
              memory: 40Mi
          securityContext: {}
          terminationMessagePolicy: FallbackToLogsOnError
          volumeMounts:
            - mountPath: /etc/tls/private
              name: prometheus-operator-tls
              readOnly: false
            - mountPath: /etc/configmaps/operator-cert-ca-bundle
              name: operator-certs-ca-bundle
              readOnly: false
      nodeSelector:
        beta.kubernetes.io/os: linux
        node-role.kubernetes.io/master: ''
      priorityClassName: system-cluster-critical
      securityContext: {}
      serviceAccountName: redhat-marketplace-prometheus-operator
      tolerations:
        - effect: NoSchedule
          key: node-role.kubernetes.io/master
          operator: Exists
      volumes:
        - name: prometheus-operator-tls
          secret:
            secretName: prometheus-operator-tls
        - configMap:
            name: operator-certs-ca-bundle
          name: operator-certs-ca-bundle
