Upgrading the operator manually

To upgrade the operator, you can edit and apply all the YAML files manually.

About this task

The operator has certain descriptors that must be applied for both OpenShift Container Platform (OCP) and Cloud Native Computing Foundation (CNCF) platforms. The operator also has descriptors that must be applied for either OCP or CNCF depending on your platform.

For both OCP and CNCF platforms
The following descriptors must be applied for both OpenShift Container Platform (OCP) and Cloud Native Computing Foundation (CNCF):
  • descriptors/fncm_v1_fncm_crd.yaml that contains the description of the Custom Resource Definition (CRD).
  • descriptors/role.yaml that defines the access of the operator.
  • descriptors/role_binding.yaml that defines the access of the operator.
  • descriptors/service_account.yaml that defines the identity for processes that run inside the pods of the operator.
OpenShift Container Platform only
For OCP, the files that need to be applied are:
  • descriptors/cluster_role.yaml that defines cluster-wide access of the operator.
  • descriptors/cluster_role_binding.yaml that defines cluster-wide access of the operator.
  • descriptors/op-olm/catalogsource.yaml that stores metadata about operators and dependencies.
  • descriptors/op-olm/operator_group.yaml that specifies the target namespace for the installation.
  • descriptors/op-olm/subscription.yaml that specifies the version of the operator that is installed.
Cloud Native Computing Foundation (CNCF) only
For CNCF, the files that need to be applied are:
  • descriptors/operator.yaml that defines the deployment of the operator.

Use the following steps to complete the setup.

Procedure

  1. Download the appropriate repository to a Linux® based machine (RHEL, CentOS, and macOS) and go to the container-samples directory.

    For more information about downloading container-samples, see Preparing a client to connect to the cluster.

  2. Log in to the target cluster as the <cluster-admin> user.
  3. (OCP Only) Edit the necessary YAML files, based on your deployment platform.
    Table 1. OCP deployment files
    File Value Comment
    descriptors/op-olm/operator_group.yaml REPLACE_NAMESPACE Replace with your deployment namespace
    descriptors/op-olm/subscription.yaml REPLACE_NAMESPACE Replace with your deployment namespace
    descriptors/cluster_role_binding.yaml NAMESPACE Replace with your deployment namespace
  4. Deploy each file based on your platform.
    • For OCP:
      oc apply -f ./descriptors/fncm_v1_fncm_crd.yaml 
      oc apply -f ./descriptors/service_account.yaml 
      oc apply -f ./descriptors/role.yaml 
      oc apply -f ./descriptors/role_binding.yaml
      oc apply -f ./descriptors/cluster_role.yaml
      oc apply -f ./descriptors/cluster_role_binding.yaml
      oc apply -f ./descriptors/op-olm/catalogsource.yaml
      oc apply -f ./descriptors/op-olm/operator_group.yaml
      oc apply -f ./descriptors/op-olm/subscription.yaml
    • For CNCF:
      kubectl apply -f ./descriptors/fncm_v1_fncm_crd.yaml 
      kubectl apply -f ./descriptors/service_account.yaml 
      kubectl apply -f ./descriptors/role.yaml 
      kubectl apply -f ./descriptors/role_binding.yaml 
      kubectl apply -f ./descriptors/operator.yaml
  5. Monitor the operator pod until it shows a STATUS of "Running".
    oc get pods -w 

What to do next

To validate your upgraded deployment, see topic Verifying the upgrade.