Chapter 5. Connecting to AMQ Management Console for an Operator-based broker deployment
Each broker Pod in an Operator-based deployment hosts its own instance of AMQ Management Console at port 8161. To provide access to the console for each broker, you can configure the Custom Resource (CR) instance for the broker deployment to instruct the Operator to automatically create a dedicated Service and Route for each broker Pod.
The following procedures describe how to connect to AMQ Management Console for a deployed broker.
Prerequisites
- You must have created a broker deployment using the AMQ Broker Operator. For example, to learn how to use a sample CR to create a basic broker deployment, see Section 3.4.1, “Deploying a basic broker instance”.
-
To instruct the Operator to automatically create a Service and Route for each broker Pod in a deployment for console access, you must set the value of the
console.expose
property totrue
in the Custom Resource (CR) instance used to create the deployment. The default value of this property isfalse
. For a complete Custom Resource configuration reference, including configuration of theconsole
section of the CR, see Section 8.1, “Custom Resource configuration reference”.
5.1. Connecting to AMQ Management Console
When you set the value of the console.expose
property to true
in the Custom Resource (CR) instance used to create a broker deployment, the Operator automatically creates a dedicated Service and Route for each broker Pod, to provide access to AMQ Management Console.
The default name of the automatically-created Service is in the form <custom-resource-name>-wconsj-<broker-pod-ordinal>-svc
. For example, my-broker-deployment-wconsj-0-svc
. The default name of the automatically-created Route is in the form <custom-resource-name>-wconsj-<broker-pod-ordinal>-svc-rte
. For example, my-broker-deployment-wconsj-0-svc-rte
.
This procedure shows you how to access the console for a running broker Pod.
Procedure
In the OpenShift Container Platform web console, click
. On the Routes page, identify the
wconsj
Route for the given broker Pod. For example,my-broker-deployment-wconsj-0-svc-rte
.Under Location, click the link that corresponds to the Route.
A new tab opens in your web browser.
Click the Management Console link.
The AMQ Management Console login page opens.
To log in to the console, enter the values specified for the
adminUser
andadminPassword
properties in the Custom Resource (CR) instance used to create your broker deployment.If there are no values explicitly specified for
adminUser
andadminPassword
in the CR, follow the instructions in Section 5.2, “Accessing AMQ Management Console login credentials” to retrieve the credentials required to log in to the console.NoteValues for
adminUser
andadminPassword
are required to log in to the console only if therequireLogin
property of the CR is set totrue
. This property specifies whether login credentials are required to log in to the broker and the console. IfrequireLogin
is set tofalse
, you can log in to the console without supplying a valid username password by entering any text when prompted for username and password.
5.2. Accessing AMQ Management Console login credentials
If you do not specify a value for adminUser
and adminPassword
in the Custom Resource (CR) instance used for your broker deployment, the Operator automatically generates these credentials and stores them in a secret. The default secret name is in the form <custom-resource-name>-credentials-secret
, for example, my-broker-deployment-credentials-secret
.
Values for adminUser
and adminPassword
are required to log in to the management console only if the requireLogin
parameter of the CR is set to true
.
If requireLogin
is set to false
, you can log in to the console without supplying a valid username password by entering any text when prompted for username and password.
This procedure shows how to access the login credentials.
Procedure
See the complete list of secrets in your OpenShift project.
-
From the OpenShift Container Platform web console, click
. From the command line:
$ oc get secrets
-
From the OpenShift Container Platform web console, click
Open the appropriate secret to reveal the Base64-encoded console login credentials.
- From the OpenShift Container Platform web console, click the secret that includes your broker Custom Resource instance in its name. Click the YAML tab.
From the command line:
$ oc edit secret <my-broker-deployment-credentials-secret>
To decode a value in the secret, use a command such as the following:
$ echo 'dXNlcl9uYW1l' | base64 --decode console_admin
Additional resources
- To learn more about using AMQ Management Console to view and manage brokers, see Managing brokers using AMQ Management Console in Managing AMQ Broker.