Manually creating projects (namespaces) for an instance of IBM Cloud Pak for Data

The IBM Cloud Pak for Data command-line interface can automatically create any projects that don't exist on the cluster. However, you can optionally create the projects manually.

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 from a private container registry
You are here icon. Preparing the cluster for Cloud Pak for Data
You are not here. Preparing to install an instance of Cloud Pak for Data
You are not here. Installing an instance of Cloud Pak for Data
Who needs to complete this task?

Cluster administrator You must be a cluster administrator to create projects.

When do you need to complete this task?

This task is optional.

  • Skip this task if you want to allow the IBM Cloud Pak for Data command-line interface (cpd-cli) to automatically create the projects for an instance of Cloud Pak for Data.
  • Complete this task only if you do not want to allow the IBM Cloud Pak for Data command-line interface (cpd-cli) to automatically create the projects for an instance of Cloud Pak for Data.

    Repeat as needed If you plan to install multiple instances of Cloud Pak for Data, you can repeat this task for each instance that you plan to install.

Before you begin

  1. Review the guidance in Supported project (namespace) configurations.
  2. Determine whether this instance of Cloud Pak for Data will have any tethered projects. If yes, determine the number of tethered projects.
    Restriction: Only some services can deploy workloads or service instances to tethered projects. To determine if the services that you plan to install can use tethered projects, see Multitenancy support.

    Many services support only one service instance in a given project. So if you want to create multiple instances of a service, you must deploy each instance of the service in a different project. You can achieve this by creating multiple tethered projects and creating one instance of the service in each tethered project.

    You can co-locate service instances and workloads for different services in the same tethered project, or you can create different tethered projects if one service or workload requires more privileges. You can use different tethered projects to give each service instance or workload the privileges it needs to align with the Principle of Least Privileges.

Best practice: You can run the commands in this task exactly as written if you set up environment variables. For instructions, see Setting up installation environment variables.

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

Procedure

To create the required projects:

  1. Log in to Red Hat® OpenShift® Container Platform as a cluster administrator.
    oc login ${OCP_URL}
  2. Create the operators project for the instance:
    oc new-project ${PROJECT_CPD_INST_OPERATORS}
  3. Create the operands project for the instance:
    oc new-project ${PROJECT_CPD_INST_OPERANDS}
  4. Optional: Create any tethered projects for the instance:
    oc new-project ${PROJECT_CPD_INSTANCE_TETHERED}

    Repeat this step for each tethered project that you want to create.

    Tip: If you set the PROJECT_CPD_INSTANCE_TETHERED_LIST environment variable, print the list of tethered projects to the terminal:
    echo $PROJECT_CPD_INSTANCE_TETHERED_LIST
    Use this information to set the PROJECT_CPD_INSTANCE_TETHERED environment variable before you re-run the oc new-project command.
    export PROJECT_CPD_INSTANCE_TETHERED=<project-name>

What to do next

Now that you've created the projects for the instance of Cloud Pak for Data, you're ready to complete Applying the required permissions to the projects (namespaces) for an instance of IBM Cloud Pak for Data.