Logging in

You can configure Event Streams for external access to the Event Streams UI and CLI. For OpenShift Container Platform, Event Streams uses routes to access the UI and CLI. You can use ingress to access the UI on other Kubernetes platforms.

Log in to Event Streams UI and CLI as follows:

  1. Retrieve the URL of your instance.
  2. Use the URL to log in to your instance.

Logging in to Event Streams UI

You can retrieve the URL for accessing the Event Streams UI:

  • By using the OpenShift Container Platform web console.
  • By using the Kubernetes command-line tool (kubectl).

Using the OpenShift Container Platform web console

Use the OpenShift web console to retrieve the URL for your Event Streams UI as follows:

  1. Log in to the OpenShift Container Platform web console using your login credentials.
  2. Expand Operators in the navigation on the left, and click Installed Operators.

    Operators > Installed Operators

  3. Locate the operator that manages your Event Streams instance in the namespace. It is called Event Streams in the NAME column.
  4. Click the Event Streams link in the row and click the Event Streams tab. This lists the Event Streams instances related to this operator.
  5. Find your instance in the Name column and click the link for the instance.

    Event Streams > Event Streams > Instance

  6. A link to the Event Streams UI is displayed under the label Admin UI. Click the link to open the Event Streams UI login page in your browser tab.
  7. Log in to your Event Streams UI from a supported web browser. Use your credentials provided to you by your cluster administrator. A cluster administrator can manage access rights by following the instructions in managing access. Enter your username and password to access the Event Streams UI.

Using the Kubernetes command-line tool (kubectl)

To retrieve the URL for your Event Streams UI, use the following commands:

  1. Log in to your Kubernetes cluster as a cluster administrator by setting your kubectl context.
  2. Find the URL of your services as follows.
    • If you are running with route endpoint, run the following command:

      kubectl get routes -n <namespace> -l app.kubernetes.io/name=admin-ui
      
    • If you are running with ingress endpoint, run the following command:

      kubectl get ingress -n <namespace> -l app.kubernetes.io/name=admin-ui
      

      The following is an example output, and you use the value from the HOST/PORT column to log in to your UI in a web browser:

      NAME                        HOST/PORT                                                           PATH   SERVICES                    PORT   TERMINATION   WILDCARD
      my-eventstreams-ibm-es-ui   my-eventstreams-ibm-es-ui-myproject.apps.my-cluster.my-domain.com          my-eventstreams-ibm-es-ui   3000   reencrypt     None
      
  3. Enter the address in a web browser. Add https:// in front of the HOST/PORT value. For example:

    https://my-eventstreams-ibm-es-ui-myproject.apps.my-cluster.my-domain.com
    
  4. Log in to your Event Streams UI from a supported web browser. Use your credentials provided to you by your cluster administrator. A cluster administrator can manage access rights by following the instructions in managing access. Enter your username and password to access the Event Streams UI.

Logging in to Event Streams CLI

You can retrieve the URL for accessing the Event Streams CLI:

  • By using the OpenShift Container Platform web console.
  • By using the Kubernetes command-line tool (kubectl).

Note: The Event Streams CLI is not available when configuring Event Streams with Keycloak.

Using the OpenShift Container Platform web console

Use the OpenShift web console to retrieve the URL for your Event Streams CLI as follows:

  1. Log in to the OpenShift Container Platform web console using your login credentials.
  2. Expand Networking in the navigation on the left, and select Routes.

    Networking > Routes

  3. Expand the Project at the top of the page and select ibm-common-services.

    The following is an example output, and you use the value from the Location column for the cp-console entry to log in to your CLI in a terminal window:

    Project

  4. Enter the address on your login command in a terminal. For example:

    cloudctl login -a https://cp-console.apps.my-cluster.my-domain.com
    
  5. Use your credentials provided to you by your cluster administrator. A cluster administrator can manage access rights by following the instructions in managing access. Enter your username and password to access the Event Streams CLI.
  6. Initialize the Event Streams plugin by running the following command:

    cloudctl es init -n <namespace>
    

Using the Kubernetes command-line tool (kubectl)

The process for initializing the Event Streams CLI is different depending on the configured authentication type:

  • Salted Challenge Response Authentication Mechanism (SCRAM)
  • IBM Cloud Pak foundational services Identity and Access Management (IAM)

Authentication type set to SCRAM

When you have the authentication type set to SCRAM, obtain the required credentials and endpoints, and then initialize and log in to the Event Streams CLI as follows:

  1. Obtain the following credentials and endpoints from your cluster administrator:
    • Username
    • Password
    • Admin API URL
    • Schema registry URL

    A cluster administrator can retrieve credentials and manage access rights by following the instructions in managing access.

  2. Using the credentials and information you obtained earlier, initialize the Event Streams plugin by running the following command:

    kubectl es init --auth-type scram-sha-512
    

    Note: For the Event Streams CLI plugin to be set up, ensure you add auth-type as scram-sha-512. If auth-type is not present, the cluster will set up IAM as the authentication type by default. For more information, see configuring UI and CLI security.

  3. Enter the credentials and endpoints when prompted to log in to the Event Streams CLI.

    Alternatively, instead of waiting for the prompt, you can also run the command with all the credentials and endpoints as additional arguments in one command as follows:

    kubectl es init --auth-type scram-sha-512 --username <USERNAME> --password <PASSWORD> --api-url <ADMIN_API_URL> --schema-reg-url <SCHEMA_REGISTRY_URL>
    

Authentication type set to IAM

Note: Identity and Access Management (IAM) authentication is only available on the OpenShift Container Platform with IBM Cloud Pak foundational services 3.x releases. It is not supported on other Kubernetes platforms.

When you have the authentication type set to IAM, retrieve the login URL for the Event Streams CLI, then log in and initialize the CLI as follows:

  1. Log in to your Kubernetes cluster as a cluster administrator by setting your kubectl context.
  2. Run the following command:

    kubectl get routes -n ibm-common-services -l app.kubernetes.io/name=management-ingress
    

    The following is an example output, and you use the value from the HOST/PORT column for the cp-console entry to log in to your CLI in a terminal:

    NAME         HOST/PORT                                  PATH   SERVICES                   PORT    TERMINATION            WILDCARD
    cp-console   cp-console.apps.my-cluster.my-domain.com          icp-management-ingress     https   reencrypt/Redirect     None
    cp-proxy     cp-proxy.apps.my-cluster.my-domain.com            nginx-ingress-controller   https   passthrough/Redirect   None
    
  3. Enter the address on your login command in a terminal. Add https:// in front of the HOST/PORT value. For example:
    cloudctl login -a https://cp-console.apps.my-cluster.my-domain.com
    
  4. Use your credentials provided to you by your cluster administrator. A cluster administrator can manage access rights by following the instructions in managing access. Enter your username and password to access the Event Streams CLI.
  5. Initialize the Event Streams plugin by running the following command:
    cloudctl es init -n <namespace>
    

Logging out

To log out of Event Streams:

  1. In your Event Streams UI, click the user icon.
  2. Click Log out.