apiVersion: operators.coreos.com/v1alpha1
kind: ClusterServiceVersion
metadata:
  annotations:
    alm-examples: |-
      [
        {
          "apiVersion": "ptp.openshift.io/v1",
          "kind": "NodePtpDevice",
          "metadata": {
            "name": "node.example.com"
          },
          "spec": {}
        },
        {
          "apiVersion": "ptp.openshift.io/v1",
          "kind": "PtpConfig",
          "metadata": {
            "name": "example-ptpconfig"
          },
          "spec": {
            "profile": [
              {
                "interface": "ens787f1",
                "name": "profile1",
                "phc2sysOpts": "-a -r",
                "ptp4lOpts": "-s -2",
                "ptpClockThreshold": {}
              }
            ],
            "recommend": [
              {
                "match": [
                  {
                    "nodeLabel": "node-role.kubernetes.io/worker=",
                    "nodeName": "node.example.com"
                  }
                ],
                "priority": 4,
                "profile": "profile1"
              }
            ]
          }
        },
        {
          "apiVersion": "ptp.openshift.io/v1",
          "kind": "PtpOperatorConfig",
          "metadata": {
            "name": "default"
          },
          "spec": {
            "daemonNodeSelector": {
              "feature.node.kubernetes.io/ptp-capable": "yes",
              "node-role.kubernetes.io/worker": ""
            },
            "ptpEventConfig": {}
          }
        }
      ]
    capabilities: Basic Install
    categories: Networking
    certified: "false"
    containerImage: quay.io/openshift/origin-ptp-operator:4.9
    createdAt: "2019-10-14"
    description: This software enables configuration of Precision Time Protocol(PTP)
      on Kubernetes. It detects hardware capable PTP devices on each node, and configures
      linuxptp processes such as ptp4l, phc2sys and timemaster.
    olm.skipRange: '>=4.3.0-0 <4.9.0'
    operators.openshift.io/infrastructure-features: '["disconnected"]'
    operators.operatorframework.io/builder: operator-sdk-v1.8.0+git
    operators.operatorframework.io/project_layout: go.kubebuilder.io/v3
    provider: Red Hat
    repository: https://github.com/openshift/ptp-operator
    support: Red Hat
  name: ptp-operator.v4.9.0
  namespace: openshift-ptp
spec:
  apiservicedefinitions: {}
  customresourcedefinitions:
    owned:
    - description: NodePtpDevice is the Schema for the nodeptpdevices API
      displayName: Node Ptp Device
      kind: NodePtpDevice
      name: nodeptpdevices.ptp.openshift.io
      version: v1
    - description: PtpConfig is the Schema for the ptpconfigs API
      displayName: Ptp Config
      kind: PtpConfig
      name: ptpconfigs.ptp.openshift.io
      version: v1
    - description: PtpOperatorConfig is the Schema for the ptpoperatorconfigs API
      displayName: Ptp Operator Config
      kind: PtpOperatorConfig
      name: ptpoperatorconfigs.ptp.openshift.io
      version: v1
  description: |
    # Precision Time Protocol (PTP) Operator for Openshift

    ## Introdution
    PTP Operator manages cluster wide PTP configuration.
    This operator has to run in namespace 'openshift-ptp'. An Operator Group is also required to install this operator:
    ```
    $ oc create -f - <<EOF
    apiVersion: v1
    kind: Namespace
    metadata:
      name: openshift-ptp
      labels:
        name: openshift-ptp
        openshift.io/cluster-monitoring: "true"
    EOF

    $ oc create -f - <<EOF
    apiVersion: operators.coreos.com/v1
    kind: OperatorGroup
    metadata:
      name: ptp-operators
      namespace: openshift-ptp
    spec:
      targetNamespaces:
      - openshift-ptp
    EOF
    ```
  displayName: PTP Operator
  icon:
  - base64data: [encoded data, 14140 characters]
    mediatype: image/png
  install:
    spec:
      clusterPermissions:
      - rules:
        - apiGroups:
          - ptp.openshift.io
          resources:
          - '*'
          verbs:
          - '*'
        - apiGroups:
          - authentication.k8s.io
          resources:
          - tokenreviews
          verbs:
          - create
        - apiGroups:
          - authorization.k8s.io
          resources:
          - subjectaccessreviews
          verbs:
          - create
        serviceAccountName: linuxptp-daemon
      - rules:
        - apiGroups:
          - ""
          resources:
          - nodes
          verbs:
          - '*'
        - apiGroups:
          - ""
          resources:
          - pods
          verbs:
          - '*'
        - apiGroups:
          - ""
          resources:
          - configmaps
          verbs:
          - '*'
        - apiGroups:
          - ""
          resources:
          - namespaces
          verbs:
          - '*'
        - apiGroups:
          - ""
          resources:
          - services
          verbs:
          - '*'
        - apiGroups:
          - ""
          resources:
          - serviceaccounts
          verbs:
          - '*'
        - apiGroups:
          - apps
          resources:
          - daemonsets
          verbs:
          - '*'
        - apiGroups:
          - apps
          resources:
          - replicasets
          verbs:
          - '*'
        - apiGroups:
          - apps
          resources:
          - deployments
          verbs:
          - '*'
        - apiGroups:
          - ptp.openshift.io
          resources:
          - '*'
          verbs:
          - '*'
        - apiGroups:
          - monitoring.coreos.com
          resources:
          - servicemonitors
          verbs:
          - '*'
        - apiGroups:
          - monitoring.coreos.com
          resources:
          - prometheusrules
          verbs:
          - '*'
        - apiGroups:
          - rbac.authorization.k8s.io
          resources:
          - roles
          verbs:
          - '*'
        - apiGroups:
          - rbac.authorization.k8s.io
          resources:
          - rolebindings
          verbs:
          - '*'
        - apiGroups:
          - ptp.openshift.io
          resources:
          - ptpconfigs
          verbs:
          - create
          - delete
          - get
          - list
          - patch
          - update
          - watch
        - apiGroups:
          - ptp.openshift.io
          resources:
          - ptpconfigs/finalizers
          verbs:
          - update
        - apiGroups:
          - ptp.openshift.io
          resources:
          - ptpconfigs/status
          verbs:
          - get
          - patch
          - update
        - apiGroups:
          - ptp.openshift.io
          resources:
          - ptpoperatorconfigs
          verbs:
          - create
          - delete
          - get
          - list
          - patch
          - update
          - watch
        - apiGroups:
          - ptp.openshift.io
          resources:
          - ptpoperatorconfigs/finalizers
          verbs:
          - update
        - apiGroups:
          - ptp.openshift.io
          resources:
          - ptpoperatorconfigs/status
          verbs:
          - get
          - patch
          - update
        serviceAccountName: ptp-operator
      deployments:
      - name: ptp-operator
        spec:
          replicas: 1
          selector:
            matchLabels:
              name: ptp-operator
          strategy: {}
          template:
            metadata:
              annotations:
                target.workload.openshift.io/management: '{"effect": "PreferredDuringScheduling"}'
              labels:
                name: ptp-operator
            spec:
              containers:
              - args:
                - --enable-leader-election
                command:
                - ptp-operator
                env:
                - name: OPERATOR_NAME
                  value: ptp-operator
                - name: RELEASE_VERSION
                  value: v4.9.0
                - name: LINUXPTP_DAEMON_IMAGE
                  value: quay.io/openshift/origin-ptp:4.9
                - name: KUBE_RBAC_PROXY_IMAGE
                  value: quay.io/openshift/origin-kube-rbac-proxy:4.9
                - name: SIDECAR_EVENT_IMAGE
                  value: quay.io/openshift/origin-cloud-event-proxy:4.9
                - name: WATCH_NAMESPACE
                  valueFrom:
                    fieldRef:
                      fieldPath: metadata.annotations['olm.targetNamespaces']
                - name: POD_NAME
                  valueFrom:
                    fieldRef:
                      fieldPath: metadata.name
                image: quay.io/openshift/origin-ptp-operator:4.9.0
                imagePullPolicy: Always
                name: ptp-operator
                resources:
                  requests:
                    cpu: 50m
                    memory: 100Mi
              nodeSelector:
                node-role.kubernetes.io/master: ""
              serviceAccountName: ptp-operator
              tolerations:
              - effect: NoSchedule
                key: node-role.kubernetes.io/master
                operator: Exists
      permissions:
      - rules:
        - apiGroups:
          - security.openshift.io
          resourceNames:
          - privileged
          resources:
          - securitycontextconstraints
          verbs:
          - use
        serviceAccountName: linuxptp-daemon
      - rules:
        - apiGroups:
          - ""
          resources:
          - configmaps
          verbs:
          - get
          - list
          - watch
          - create
          - update
          - patch
          - delete
        - apiGroups:
          - coordination.k8s.io
          resources:
          - leases
          verbs:
          - get
          - list
          - watch
          - create
          - update
          - patch
          - delete
        - apiGroups:
          - ""
          resources:
          - events
          verbs:
          - create
          - patch
        serviceAccountName: ptp-operator
    strategy: deployment
  installModes:
  - supported: true
    type: OwnNamespace
  - supported: true
    type: SingleNamespace
  - supported: false
    type: MultiNamespace
  - supported: false
    type: AllNamespaces
  keywords:
  - ptp
  links:
  - name: Documentation operator
    url: https://github.com/openshift/ptp-operator
  - name: Documentation operand
    url: https://github.com/openshift/linuxptp-daemon
  maintainers:
  - email: support@redhat.com
    name: Red Hat
  maturity: alpha
  provider:
    name: Red Hat
  version: 4.9.0
