Installing Red Hat OpenShift Serverless Knative Eventing

If you plan to install IBM watsonx Assistant or IBM watsonx™ Orchestrate, you must have Red Hat OpenShift Serverless Knative Eventing and IBM Events on the cluster.

Installation phase
  • You are not here. Setting up a client workstation
  • You are not here. Setting up a cluster
  • You are not here. Collecting required information
  • You are not here. Preparing to run installs in a restricted network
  • You are not here. Preparing to run installs from a private container registry
  • You are here icon. Preparing the cluster for IBM Software Hub
  • You are not here. Preparing to install an instance of IBM Software Hub
  • You are not here. Installing an instance of IBM Software Hub
  • You are not here. Setting up the control plane
  • You are not here. Installing solutions and services
Who needs to complete this task?

Cluster administrator A cluster administrator must install this software.

When do you need to complete this task?
Complete this task only if you plan to install one of the following services:
  • watsonx Assistant
  • watsonx Orchestrate

One-time setup The Red Hat OpenShift Serverless Knative Eventing and IBM Events are installed once and shared by all instances of watsonx Assistant or watsonx Orchestrate on the cluster.

Before you begin

Before you install Red Hat OpenShift Serverless Knative Eventing, ensure that the project where you want to install the software exists. If it does not exist, run:
oc new-project ${PROJECT_IBM_EVENTS}
Important: Complete the remaining steps in the Before you begin section only if your cluster is in a restricted network.

If your cluster is not in a restricted network, skip this section and go to About this task.

If your cluster is in a restricted network, you have two options for ensuring you can access the required images:

Option 1
You can run the deploy-knative-eventing command while the workstation is connected to the cluster and the following websites:
  • Red Hat OpenShift image registry
  • IBM Entitled Registry
  • GitHub (optional)
Option 2
You can preinstall the Red Hat OpenShift Serverless Operator and IBM Events Operator:
  1. You must install the Red Hat OpenShift Serverless Operator before you complete this task. For more information, see Installing the OpenShift Serverless Operator:
    To mirror the images for the Red Hat OpenShift Serverless Operator to a private container registry, see Mirroring images for a disconnected installation
  2. You must have the IBM Cloud Pak foundational services CASE package in the work directory on the workstation from which you will complete this task.
    If you do not have the CASE package, you must run the following command while the client workstation is connected to the internet:
    GitHub
    cpd-cli manage case-download \
    --components=cpfs \
    --release=${VERSION}

    IBM Cloud Pak Open Container Initiative
    cpd-cli manage case-download \
    --components=cpfs \
    --release=${VERSION} \
    --from_oci=true

    Some other Open Container Initiative repository
    cpd-cli manage case-download \
    --components=cpfs \
    --release=${VERSION} \
    --from_oci=true \
    --oci_location=${OCI_REGISTRY_LOCATION}

  3. If the IBM Events Operator is not installed on your cluster, run the following commands:
    1. Authorize the projects where the software will be installed to communicate:
      cpd-cli manage authorize-instance-topology \
      --release=${VERSION} \
      --cpd_operator_ns=ibm-knative-events \
      --cpd_instance_ns=knative-eventing
    2. Install the IBM Events Operator in the ibm-knative-events project:
      cpd-cli manage setup-instance-topology \
      --release=${VERSION} \
      --cpd_operator_ns=ibm-knative-events \
      --cpd_instance_ns=knative-eventing \
      --block_storage_class=${STG_CLASS_BLOCK} \
      --license_acceptance=true
Best practice: You can run the commands in this task exactly as written if you use your installation environment variables script.

Ensure that you source the environment variables before you run the commands in this task.

About this task

When a user adds, modifies, or deletes actions in an assistant, watsonx Assistant starts a training job. The watsonx Assistant user interface communicates with the machine learning model through a message broker.

Red Hat OpenShift Serverless Knative Eventing and IBM Events provide a central Kafka broker for any instances of watsonx Assistant on the cluster.

You can run the deploy-knative-eventing command to install the Red Hat OpenShift Serverless Knative Eventing and IBM Events software.

The command is recommended for the following scenarios:
  • Installing a proof-of-concept or evaluation environment
  • Setting up a simple Kafka instance for use with IBM Software Hub
If you want to set up a custom Kafka instance or you want to connect to an existing Kafka instance, follow the Red Hat OpenShift Serverless documentation:

When you run the deploy-knative-eventing command, the following operators are installed once and shared by all instances of IBM Software Hub on the cluster:

Software Installation project
Red Hat OpenShift Serverless Operator

This software is installed in the openshift-serverless project.

Knative Eventing Operator

This software is installed in the knative-eventing project.

Knative Kafka Operator

This software is installed in the knative-eventing project.

IBM Events Operator

This software is installed in the ibm-knative-events project.

However, if you have an existing IBM Events Operator installation, you can optionally point to the operator associated with that installation if it is cluster-scoped.

Important: The IBM Events Operator that is provided by IBM Software Hub is not a cluster-scoped operator. The operator is scoped only to instances of IBM Software Hub.

In addition, the command sets up a Knative broker in the knative-eventing project. The broker is backed by an instance of Apache Kafka that is managed by the IBM Events Operator.

Procedure

To install Red Hat OpenShift Serverless Knative Eventing:

  1. Log the cpd-cli in to the Red Hat OpenShift Container Platform cluster:
    ${CPDM_OC_LOGIN}
    Remember: CPDM_OC_LOGIN is an alias for the cpd-cli manage login-to-ocp command.
  2. Install the Red Hat OpenShift Serverless Knative Eventing software.
    The command that you run depends on several factors:
    • Whether you want to install the IBM Events Operator in the ibm-knative-events project or whether you want to point to an existing cluster-scoped instance of the IBM Events Operator.
    • Whether you have the required CASE packages on the client workstation.

      If you don't have the required CASE packages, whether you want to download the CASE packages from GitHub, IBM Cloud Pak Open Container Initiative, or from another Open Container Initiative registry.

    • Whether you are using Portworx storage.
    Install the operator in the ibm-knative-events project

    CASE packages are on the client workstation
    Note: By default, the deploy-knative-eventing command scales unused Red Hat OpenShift Serverless Knative Eventing replicas to 0 (zero). To prevent this behavior, append the following line to the command:
    --patch_redhat_crd=false
    Portworx storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --storage_vendor=portworx
    All other storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --block_storage_class=${STG_CLASS_BLOCK}

    CASE packages will be downloaded from GitHub
    Note: By default, the deploy-knative-eventing command scales unused Red Hat OpenShift Serverless Knative Eventing replicas to 0 (zero). To prevent this behavior, append the following line to the command:
    --patch_redhat_crd=false
    Portworx storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --storage_vendor=portworx
    All other storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --block_storage_class=${STG_CLASS_BLOCK}

    CASE packages will be downloaded from IBM Cloud Pak Open Container Initiative
    Note: By default, the deploy-knative-eventing command scales unused Red Hat OpenShift Serverless Knative Eventing replicas to 0 (zero). To prevent this behavior, append the following line to the command:
    --patch_redhat_crd=false
    Portworx storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --storage_vendor=portworx \
    --from_oci=true
    All other storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --block_storage_class=${STG_CLASS_BLOCK} \
    --from_oci=true

    CASE packages will be downloaded from another Open Container Initiative registry
    Note: By default, the deploy-knative-eventing command scales unused Red Hat OpenShift Serverless Knative Eventing replicas to 0 (zero). To prevent this behavior, append the following line to the command:
    --patch_redhat_crd=false
    Portworx storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --storage_vendor=portworx \
    --from_oci=true \
    --oci_location=${OCI_REGISTRY_LOCATION}
    All other storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --block_storage_class=${STG_CLASS_BLOCK} \
    --from_oci=true \
    --oci_location=${OCI_REGISTRY_LOCATION}

    Use an existing cluster-scoped instance of the operator

    CASE packages are on the client workstation
    Note: By default, the deploy-knative-eventing command scales unused Red Hat OpenShift Serverless Knative Eventing replicas to 0 (zero). To prevent this behavior, append the following line to the command:
    --patch_redhat_crd=false
    Portworx storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --storage_vendor=portworx \
    --events_operator_ns=${PROJECT_IBM_EVENTS}
    All other storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --block_storage_class=${STG_CLASS_BLOCK} \
    --events_operator_ns=${PROJECT_IBM_EVENTS}

    CASE packages will be downloaded from GitHub
    Note: By default, the deploy-knative-eventing command scales unused Red Hat OpenShift Serverless Knative Eventing replicas to 0 (zero). To prevent this behavior, append the following line to the command:
    --patch_redhat_crd=false
    Portworx storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --storage_vendor=portworx
    All other storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --block_storage_class=${STG_CLASS_BLOCK}

    CASE packages will be downloaded from IBM Cloud Pak Open Container Initiative
    Note: By default, the deploy-knative-eventing command scales unused Red Hat OpenShift Serverless Knative Eventing replicas to 0 (zero). To prevent this behavior, append the following line to the command:
    --patch_redhat_crd=false
    Portworx storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --storage_vendor=portworx \
    --events_operator_ns=${PROJECT_IBM_EVENTS} \
    --from_oci=true
    All other storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --block_storage_class=${STG_CLASS_BLOCK} \
    --events_operator_ns=${PROJECT_IBM_EVENTS} \
    --from_oci=true

    CASE packages will be downloaded from another Open Container Initiative registry
    Note: By default, the deploy-knative-eventing command scales unused Red Hat OpenShift Serverless Knative Eventing replicas to 0 (zero). To prevent this behavior, append the following line to the command:
    --patch_redhat_crd=false
    Portworx storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --storage_vendor=portworx \
    --events_operator_ns=${PROJECT_IBM_EVENTS} \
    --from_oci=true \
    --oci_location=${OCI_REGISTRY_LOCATION}
    All other storage
    cpd-cli manage deploy-knative-eventing \
    --release=${VERSION} \
    --block_storage_class=${STG_CLASS_BLOCK} \
    --events_operator_ns=${PROJECT_IBM_EVENTS} \
    --from_oci=true \
    --oci_location=${OCI_REGISTRY_LOCATION}

What to do next

Now that you've installed Red Hat OpenShift Serverless Knative Eventing and IBM Events, you're ready to complete Preparing to install an instance of IBM Software Hub.