Preparing a cluster to use Azure Red Hat OpenShift (ARO)

Prepare your cluster on ARO so you can install IBM Cloud Pak® for Integration.

Requirements

To set up an ARO cluster, you need:

  • Access to the Azure portal (requires email invitation)

  • Access to a Red Hat account (requires email invitation)

Creating your cluster

The following steps are based on the Microsoft tutorial for creating an ARO cluster: Tutorial: Create an Azure Red Hat OpenShift 4 cluster

Prerequisites: Azure Red Hat OpenShift requires a minimum of 40 cores to create and run an OpenShift cluster. You will need to adjust for this, as the default Azure resource quota for a new Azure subscription does not meet this requirement.

  1. In the Azure CLI, run the following command:

    az login
  2. On the browser page that opens, log in.

  3. On the tutorial page, follow the steps under “Get a Red Hat pull secret”.

  4. Set environment variables to be used by az commands. You can replace the values with your own names. For example:

    LOCATION=eastus        # location of your cluster
    RESOURCEGROUP=aro-rg   # resource group where to create cluster
    CLUSTER=<cluster_name> # name of your cluster
  5. Create a resource group:

    az group create \
        --name $RESOURCEGROUP \
        --location $LOCATION
  6. Create a virtual network in the resource group. OpenShift 4 requires two empty subnets, one for master nodes and one for worker nodes:

    az network vnet create \
        --resource-group $RESOURCEGROUP \
        --name aro-vnet \
        --address-prefixes 10.0.0.0/22
  7. Add an empty subnet for the master nodes:

    az network vnet subnet create \
        --resource-group $RESOURCEGROUP \
        --vnet-name aro-vnet \
        --name master-subnet \
        --address-prefixes 10.0.0.0/23 \
        --service-endpoints Microsoft.ContainerRegistry
  8. Add an empty subnet for the worker nodes:

    az network vnet subnet create \
        --resource-group $RESOURCEGROUP \
        --vnet-name aro-vnet \
        --name worker-subnet \
        --address-prefixes 10.0.2.0/23 \
        --service-endpoints Microsoft.ContainerRegistry
  9. Disable subnet private endpoint policies on the master subnet. This is required for connecting to the cluster and managing it:

    az network vnet subnet update \
        --name master-subnet \
        --resource-group $RESOURCEGROUP \
        --vnet-name aro-vnet \
        --disable-private-link-service-network-policies true
  10. Create the cluster. Note the default storage is insufficient for OpenShift Data Foundation (formerly OpenShift Container Storage), which requires at least three worker nodes with 16 cores, each with 64 GB of memory. Add additional worker nodes as necessary. In the example create following command, use the pull secret you obtained earlier in the tutorial. To add these options, use: --worker-vm-size Standard_D16s_v3 --pull-secret @pull-secret.txt In the example create following command, replace the vnet and pull-secret values with your own net name and the location of the file that contains your pull secret. In this example, pull_secret.txt is the file containing the pull secret: az aro create \ --resource-group $RESOURCEGROUP \ --name $CLUSTER \ --vnet aro-vnet \ --master-subnet master-subnet \ --worker-subnet worker-subnet \ --worker-vm-size Standard_D16s_v3 \ --pull-secret @/path/pull_secret.txt When the command has finished running, your cluster is ready to use.

Connecting to your cluster

After the cluster is created, follow the instructions in the next Microsoft tutorial to connect to your cluster: Tutorial: Connect to an Azure Red Hat OpenShift 4 cluster

  1. Get login information:

    az aro list-credentials \
        --name $CLUSTER \
        --resource-group $RESOURCEGROUP
  2. Get the web console URL:

    az aro show \
        --name $CLUSTER \
        --resource-group $RESOURCEGROUP \
        --query "consoleProfile.url" -o tsv

    From here you can download the OpenShift CLI from the web console using the ? button at the top right of the page.

  3. Log in to the OpenShift CLI

    apiServer=$(az aro show -g $RESOURCEGROUP -n $CLUSTER --query apiserverProfile.url -o tsv)
    oc login $apiServer -u kubeadmin -p kubeadmin_passwd