apiVersion: operators.coreos.com/v1alpha1
kind: ClusterServiceVersion
metadata:
  # The version value is substituted by the ART pipeline
  name: clusterkubedescheduleroperator.4.6.0-202101051539.p0
  namespace: openshift-kube-descheduler-operator
  annotations:
    alm-examples: |
      [
        {
          "apiVersion": "operator.openshift.io/v1beta1",
          "kind": "KubeDescheduler",
          "metadata": {
            "name": "cluster",
            "namespace": "openshift-kube-descheduler-operator"
          },
          "spec": {
            "image": "image-registry.openshift-image-registry.svc:5000/openshift/ose-descheduler:v4.6.0-202101051539.p0",
            "deschedulingIntervalSeconds": 3600
          }
        }
      ]
    certified: "false"
    containerImage: image-registry.openshift-image-registry.svc:5000/openshift/ose-cluster-kube-descheduler-operator:v4.6.0-202101051539.p0
    createdAt: 2020/04/18
    olm.skipRange: ">=4.3.0-0 <4.6.0"
    description: An operator to run descheduler in Openshift cluster.
    repository: https://github.com/openshift/cluster-kube-descheduler-operator
    support: Red Hat, Inc.
    capabilities: Basic Install
    categories: OpenShift Optional
spec:
  customresourcedefinitions:
    owned:
    - displayName: Kube Descheduler
      description: KubeDescheduler is the Schema for the deschedulers API
      group: operator.openshift.io
      kind: KubeDescheduler
      name: kubedeschedulers.operator.openshift.io
      version: v1beta1
  description: |
      The Kube Descheduler Operator provides the ability to evict a running pod so that the pod can be rescheduled onto a more suitable node.

      There are several situations where descheduling can benefit your cluster:

      * Nodes are underutilized or overutilized.
      * Pod and node affinity requirements, such as taints or labels, have changed and the original scheduling decisions are no longer appropriate for certain nodes.
      * Node failure requires pods to be moved.
      * New nodes are added to clusters.

      ## Descheduler Strategies

      Once the operator is installed, you can configure one or more strategies to identify pods to evict. The scheduler will schedule the replacement of the evicted pods.

      The following strategies are supported:

      * `LowNodeUtilization` - This strategy finds nodes that are underutilized and evicts pods, if possible, from other nodes in the hope that recreation of evicted pods will be scheduled on these underutilized nodes.
      * `RemoveDuplicates` - This strategy ensures that there is only one pod associated with a ReplicaSet, ReplicationController, Deployment, or Job running on same node. If there are more, then those duplicate pods are evicted for better spreading of pods in a cluster.
      * `RemovePodsViolatingInterPodAntiAffinity` - This strategy ensures that pods violating inter-pod anti-affinity are removed from nodes.
      * `RemovePodsViolatingNodeAffinity` - This strategy ensures that pods violating node affinity are removed from nodes.
      * `RemovePodsViolatingNodeTaints` - This strategy ensures that pods violating `NoSchedule` taints on nodes are removed.

      These strategies are documented in detail in the [descheduler README](https://github.com/kubernetes-sigs/descheduler/#policy-and-strategies).

      ## Additional Parameters

      In addition to the strategies, the following parameters can be configured:

      * `deschedulingIntervalSeconds` - Set the number of seconds between descheduler runs. A value of `0` in this field runs the descheduler once and exits.
      * `image` - Set the descheduler container image to deploy.
      * `flags` - Set one or more flags to append to the descheduler Pod. This flag must be in the format ready to pass to the binary, such as `"--dry-run"`.
  displayName: Kube Descheduler Operator
  keywords: ["scheduling", "descheduler", "workload"]
  provider:
    name: Red Hat, Inc.
  maturity: beta
  version: 4.6.0-202101051539.p0
  icon:
  - base64data: [encoded data, 5096 characters]
    mediatype: image/png
  links:
  - name: Source Code
    url: https://github.com/openshift/cluster-kube-descheduler-operator
  maintainers:
  - email: support@redhat.com
    name: Red Hat
  minKubeVersion: 1.19.0
  labels:
    olm-owner-enterprise-app: cluster-kube-descheduler-operator
    olm-status-descriptors: cluster-kube-descheduler-operator.v4.6.0
  installModes:
  - supported: true
    type: OwnNamespace
  - supported: true
    type: SingleNamespace
  - supported: false
    type: MultiNamespace
  - supported: false
    type: AllNamespaces
  install:
    spec:
      clusterPermissions:
      - serviceAccountName: openshift-descheduler
        rules:
        - apiGroups:
          - operator.openshift.io
          resources:
          - "*"
          verbs:
          - "*"
        - apiGroups:
          - kubedeschedulers.operator.openshift.io
          resources:
          - "*"
          verbs:
          - "*"
        - apiGroups:
          - ""
          resources:
          - services
          - pods
          - configmaps
          - secrets
          - names
          - nodes
          - pods/eviction
          - events
          verbs:
          - "*"
        - apiGroups:
          - scheduling.k8s.io
          resources:
          - priorityclasses
          verbs:
          - get
          - watch
          - list
        - apiGroups:
          - apps
          resources:
          - deployments
          - replicasets
          verbs:
          - "*"
      deployments:
      - name: descheduler-operator
        spec:
          replicas: 1
          selector:
            matchLabels:
              name: descheduler-operator
          template:
            metadata:
              labels:
                name: descheduler-operator
            spec:
              containers:
                - name: descheduler-operator
                  image: image-registry.openshift-image-registry.svc:5000/openshift/ose-cluster-kube-descheduler-operator:v4.6.0-202101051539.p0
                  ports:
                  - containerPort: 60000
                    name: metrics
                  command:
                  - cluster-kube-descheduler-operator
                  args:
                  - "operator"
                  imagePullPolicy: Always
                  env:
                    - name: WATCH_NAMESPACE
                      valueFrom:
                        fieldRef:
                          fieldPath: metadata.namespace
                    - name: OPERATOR_NAME
                      value: "descheduler-operator"
              serviceAccountName: openshift-descheduler
              serviceAccount: openshift-descheduler
    strategy: deployment
