Installing Operator online with Operator Lifecycle Manager

You can choose to install the Operator on either Red Hat® OpenShift® Container Platform or a Kubernetes platform of your choice. If the beta version of the Operator is installed, uninstall it, and install the new version of the Operator.

If you are using Red Hat OpenShift Container Platform, see the following instructions. If you are using a Kubernetes platform of your choice, apply the same concepts and steps according to the specifics of your chosen platform.

Before you begin

  1. Ensure that you install a supported version of the Operator Lifecycle Manager (OLM). For more information about supported OLM versions for each release, see What's new in containers.
  2. Install the necessary command-line tools. For more information, see Prerequisites to installation with OLM.
  3. Create and configure the Operator catalog source. For more information, see Creating and configuring Operator catalog source.

About this task

Use either the Red Hat OpenShift Container Platform web console or a command-line tool.
Attention: Effective with the 10.0.2506.1 release, the Sterling Order Management System channel changed from v1.0 to v1. The versioning of the Sterling Order Management System Operator begins with v1.1.0, where the first digit represents the channel number, the second digit maps to the monthly release number, and the third digit indicates any hotfixes or fix packs that are applied to the Operator.

Procedure

  • Installing Operator in Red Hat OpenShift Container Platform
    1. Verify that the catalog source pod is running by completing the following steps:
      1. Switch to an openshift-marketplace project.
      2. Go to Workloads > Pods. Verify whether the pod is running.
    2. From the context selector in the navigation menu, click Operators > OperatorHub. The OperatorHub page opens.
    3. Enter full or partial keywords in the search textbox to look for the Operator.
      For example, enter IBM Sterling Order Management or Order Management.
    4. Click the IBM Sterling Order Management System Operator card to view its details.
    5. Click Install. The Install Operator page opens.
    6. Configure the following settings.
      • Select the Version of the Operator that is to be installed.
      • Choose from the following namespaces to deploy the Operator in.
        • All namespaces for cluster-wide installation.
        • Single namespace for a specific project or namespace.
      • Select the Update approval strategy as automatic for automatic updates or manual that requires you to manually approve updates.
    7. Click Install. The Operator is installed.

      Installation takes couple of minutes to complete and display Installed operator: ready for use message in the status section.

    8. To view the details of Operator, click View Operator.
  • Installing Operator by using oc commands
    The oc commands are interchangeable with kubectl. Hence, if you are connected to a Kubernetes cluster, ensure to replace the oc commands with kubectl counterparts.
    1. If you are using a Kubernetes cluster, create an OperatorGroup to define either cluster-wide or namespace-specific scope.
      In the following example,
      • Replace <namespace> with the necessary namespace.
      • For namespace-specific scope, replace <target_namespace> with the actual namespace name to be monitored.
      • Currently, only one option at a time that is either single namespace or all namespaces is supported.
      Note: If you manage multiple namespaces, you should install the Operator in each namespace. Although cluster-scoped installation is supported, you are encouraged to isolate the Operator installation per namespace as a best practice.

      OperatorGroup with cluster scope:
      
      oc apply -f - <<EOF
      apiVersion: operators.coreos.com/v1
      kind: OperatorGroup
      metadata:
        name: oms-operator-global
        namespace: <namespace>
      spec: {}
      EOF

      OperatorGroup with namespace-specific scope:

      oc apply -f - <<EOF
      apiVersion: operators.coreos.com/v1
      kind: OperatorGroup
      metadata:
          name: oms-operator-local
          namespace: <namespace>
      spec:
          targetNamespaces:
          - <target_namespace>
      EOF
    2. Create a subscription yaml as shown in the following example.
      oc apply -f - <<EOF
      apiVersion: operators.coreos.com/v1alpha1
      kind: Subscription
      metadata:
          name: <subscription_name>
          namespace: <namespace>
      spec:
          channel: v1
          installPlanApproval: <plan_approval>
          name: ibm-oms-<edition>
          source: <catalog_source_name>
          sourceNamespace: <CatalogSource_namespace>
      EOF
      • Replace <subscription_name> with the necessary subscription name.
      • Replace <namespace> with the namespace where you want to install the Operator.
      • Set <plan_approval> to either Manual or Automatic. If the approval strategy is Automatic, the upgrade process initiates when a new Operator version is available in the selected channel. If the approval strategy is Manual, you must manually approve pending upgrade.
      • Set <edition> to either ent for Enterprise or pro for Professional, based on the catalog source that is configured in Creating and configuring Operator catalog source.
      • Replace <catalog_source_name> with the name of the catalog source that you created.
      • Replace <CatalogSource_namespace> with the namespace where you installed the catalog source.
    3. To view the Operator installation status, run the following command.
      oc describe sub <subscription_name> -n <namespace>
    4. To view the Operator manager pod, run the following command.
      oc get pod | grep "ibm-oms-controller-manager" -n <namespace>
    5. To view the version of the installed Operator, run the following command.
      oc get sub <subscription_name> -o jsonpath=“{.status.installedCSV}” -n <namespace>