apiVersion: operators.coreos.com/v1alpha1
kind: ClusterServiceVersion
metadata:
  name: nfd.v4.7.0
  namespace: placeholder
  labels:
    "operatorframework.io/arch.amd64": supported
    "operatorframework.io/arch.ppc64le": supported
    "operatorframework.io/arch.s390x": supported
  annotations:
    capabilities: Basic Install
    categories: "Database"
    provider: Red Hat
    support: Red Hat
    containerImage: registry.redhat.io/openshift4/ose-cluster-nfd-operator:v4.7.0
    createdAt: 2019-05-30T00:00:00Z
    certified: "false"
    repository: https://github.com/openshift/cluster-nfd-operator
    alm-examples: |-
      [
       {
            "apiVersion": "nfd.openshift.io/v1",
            "kind": "NodeFeatureDiscovery",
            "metadata": {
                "name": "nfd-master-server"
            },
            "spec": {
                "operand": {
                    "image": "registry.redhat.io/openshift4/ose-node-feature-discovery:v4.7.0",
                    "imagePullPolicy": "Always",
                    "namespace": "node-feature-discovery-operator"
                },
                "workerConfig": {
                    "configData": "sources:\n  pci:\n    deviceLabelFields:\n      - \"vendor\"\n    deviceClassWhitelist:\n      - \"0200\"\n      - \"03\"\n      - \"12\"\n"
                }
            }
        }
      ]
    description: This software enables node feature discovery for Kubernetes. It detects hardware features available on each node in a Kubernetes cluster, and advertises those features using node labels.
    olm.skipRange: ">=4.5.0 <4.7.0"
spec:
  displayName: Node Feature Discovery    
  version: 4.7.0
  minKubeVersion: 1.19.0
  maintainers: 
  - name: "Red Hat"
    email: openshift-psap@redhat.com
  links: 
  - name: Documentation operator
    url: https://github.com/openshift/cluster-nfd-operator
  - name: Documentation operand
    url: https://github.com/openshift/node-feature-discovery
  apiservicedefinitions: {}
  customresourcedefinitions:
    owned:
    - kind: NodeFeatureDiscovery
      name: nodefeaturediscoveries.nfd.openshift.io
      version: v1
      description: |
        The NFD operator creates and maintains the Node Feature Discovery (NFD) on Kubernetes. 
        It detects hardware features available on each node in a Kubernetes cluster, and advertises those features using node labels.
      displayName: Node Feature Discovery    
  description: |
    The NFD operator creates and maintains the Node Feature Discovery (NFD) on Kubernetes. 
    It detects hardware features available on each node in a Kubernetes cluster, and advertises those features using node labels.
  icon: 
  - base64data: [encoded data, 14140 characters]
    mediatype: image/png
  install:
    spec:
      clusterPermissions:
      - rules:
        - apiGroups: ["rbac.authorization.k8s.io"]
          resources: ["roles", "rolebindings", "clusterroles", "clusterrolebindings"]
          verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
        - apiGroups: [""]
          resources: ["pods", "services", "endpoints", "persistentvolumeclaims", "events", "configmaps", "secrets", "serviceaccounts",  "nodes"]
          verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
        - apiGroups: [""]
          resources: ["namespaces"]
          verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
        - apiGroups: ["apps"]
          resources: ["deployments", "daemonsets", "replicasets", "statefulsets"]
          verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
        - apiGroups: ["monitoring.coreos.com"]
          resources: ["servicemonitors"]
          verbs: ["get", "create"]
        - apiGroups: ["nfd.openshift.io"]
          resources: ["deployments", "daemonsets", "replicasets", "statefulsets"]
          verbs: ["create", "delete", "get", "list", "patch", "update", "watch"]
        - apiGroups: ["policy"]
          resourceNames: ["nfd-worker"]
          resources: ["podsecuritypolicies"]
          verbs: ["use"]
        - apiGroups: ["security.openshift.io"]
          resources: ["securitycontextconstraints"]
          verbs: ["use","create", "delete", "get", "list", "patch", "update", "watch"]
        - apiGroups: ["nfd.openshift.io", "nfd.openshift.io/finalizers"]
          resources: ["nodefeaturediscoveries"]
          verbs: ["use","create", "delete", "get", "list", "patch", "update", "watch"]
        - apiGroups: ["nfd.openshift.io", "nfd.openshift.io/finalizers"]
          resources: ["nodefeaturediscoveries","nodefeaturediscoveries/finalizers"]
          verbs: ["use","create", "delete", "get", "list", "patch", "update", "watch"]
        - apiGroups:  ["nfd.openshift.io", "nfd.openshift.io/finalizers"]
          resources: ["roles", "rolebindings", "clusterroles", "clusterrolebindings", "pods", "services", "endpoints", "persistentvolumeclaims", "events", "configmaps", "secrets", "serviceaccounts", "serviceaccounts/finalizers", "nodes"]
          verbs: ["use","create", "delete", "get", "list", "patch", "update", "watch"]
        serviceAccountName: nfd-operator
      deployments:
      - name: nfd-operator
        spec:
          replicas: 1
          selector:
            matchLabels:
              name: nfd-operator
          strategy: {}
          template:
            metadata:
              labels:
                name: nfd-operator
            spec:
              containers:
              - command:
                - cluster-nfd-operator
                env:
                - name: WATCH_NAMESPACE
                  valueFrom:
                    fieldRef:
                      fieldPath: metadata.annotations['olm.targetNamespaces']
                - name: POD_NAME
                  valueFrom:
                    fieldRef:
                      fieldPath: metadata.name
                - name: OPERATOR_NAME
                  value: cluster-nfd-operator
                - name: NODE_FEATURE_DISCOVERY_IMAGE
                  value: quay.io/openshift/origin-node-feature-discovery:4.7
                image: quay.io/openshift/origin-cluster-nfd-operator:4.7
                imagePullPolicy: Always
                name: nfd-operator
                ports:
                - containerPort: 60000
                  name: metrics
                  failureThreshold: 1
                  initialDelaySeconds: 4
                  periodSeconds: 10
                resources: {}
                securityContext:
                  allowPrivilegeEscalation: false
                  capabilities:
                    drop:
                    - ALL
                  readOnlyRootFilesystem: true
              nodeSelector:
                node-role.kubernetes.io/master: ""
              serviceAccountName: nfd-operator
              tolerations:
              - effect: NoSchedule
                key: node-role.kubernetes.io/master
                operator: Equal
    strategy: deployment
  installModes:
  - supported: true
    type: OwnNamespace
  - supported: true
    type: SingleNamespace
  - supported: false
    type: MultiNamespace
  - supported: true
    type: AllNamespaces
  maturity: stable
  provider:
    name: "Red Hat"
