manage authorize-instance-topology

Apply the required roles and role bindings to the projects that are associated with an instance of IBM Software Hub.

Required role
Cluster administrator You must be a cluster administrator to run this command.

Extended description

You must run this command before you run the setup-instance command.

The authorize-instance-topology completes the following tasks:
  • Creates the specified projects if they don't already exist.
  • Creates the NamespaceScope operator in the operators project.
  • Applies the require role to the operands project and any tethered projects.
  • Binds the applied role to the service account of the NamespaceScope operator.

Run this command for each instance of IBM® Software Hub that you plan to install.

Syntax

cpd-cli manage authorize-instance-topology \
--cpd_operator_ns=<project-name> \
--cpd_instance_ns=<project-name> \
[--additional_ns=<comma-separated-list-of-project-names>] \
[--preview=true|false] \
[-v][-vv][-vvv]

Arguments

The authorize-instance-topology command has no arguments.

Options

Table 1: Command options
Option Description
--additional_ns A list of projects that you plan to tether to the IBM Software Hub control plane project.
Restriction: Only some services can deploy workloads or service instances to tethered projects. To determine whether the services that you plan to install can use tethered projects, see Multitenancy support.
Status
Optional.
Syntax
--additional_ns=<comma-separated-list-of-project-names>
Default value
No default. User defined.
Valid values
A comma-separated list of project names to tether to the IBM Software Hub operands project.
--cpd_instance_ns The project for the IBM Software Hub control plane and services.
Status
Required.
Syntax
--cpd_instance_ns=<project-name>
Default value
No default. User-defined.
Valid values
  • For install, the project where you want to install IBM Software Hub.
  • To authorize additional tethered projects, specify the project where IBM Software Hub is installed.
--cpd_operator_ns The project for the operators for an instance of IBM Software Hub.
Status
Required.
Syntax
--cpd_operator_ns=<project-name>
Default value
No default. User-defined.
Valid values
  • For install, the project where you want to install the operators.
  • To authorize additional projects, specify the project where the operators are installed.
--preview Preview the commands that run when you issue this CLI command.

The command issues a series of oc commands. You can see the list of oc commands that are associated with the command.

The oc commands are saved to the preview.sh file in the work directory.

Status
Optional.
Syntax
--preview=true|false
Default value
false

If you omit this option, the default value is used.

Valid values
false
Run the commands to apply the changes to your cluster.
true
Preview the commands without running them.

You can copy the oc commands from the output and run them yourself. However, this method is not recommended. When you run the commands manually, you do not have access to the additional helper scripts that are included in the underlying Ansible® playbook.

-v
-vv
-vvv
Display verbose output.

Options are listed from least verbose to the most verbose.

Status
Optional.
Syntax
Verbose output
-v
Very verbose output
-vv
Most verbose output
-vvv
Default value
Not applicable.
Valid values
Not applicable.

Examples

Note: The following example uses the recommended installation environment variables.

It is strongly recommended that you use a script to create environment variables with the correct values for your environment. For details, see Setting up installation environment variables.

Authorize the specified operator project to watch the project where you plan to install IBM Software Hub
cpd-cli manage authorize-instance-topology \
--cpd_operator_ns=${PROJECT_CPD_INST_OPERATORS} \
--cpd_instance_ns=${PROJECT_CPD_INST_OPERANDS}
Authorize the specified operator project to watch the project where you plan to install IBM Software Hub and a list of projects that you plan to tether to the operands project
cpd-cli manage authorize-instance-topology \
--cpd_operator_ns=${PROJECT_CPD_INST_OPERATORS} \
--cpd_instance_ns=${PROJECT_CPD_INST_OPERANDS} \
--additional_ns=${PROJECT_CPD_INSTANCE_TETHERED_LIST}
Preview the oc commands to authorize the specified operator project to watch the project where you plan to install IBM Software Hub
cpd-cli manage authorize-instance-topology \
--cpd_operator_ns=${PROJECT_CPD_INST_OPERATORS} \
--cpd_instance_ns=${PROJECT_CPD_INST_OPERANDS} \
--preview=true