Access Ansible Automation Platform through the CLI
You can use the OpenShift Container Platform CLI to fetch the web address and the password of the Automation controller that you created. To login to the platform gateway, you need the web address and the password.
Fetch the platform gateway web address Copy linkLink copied!
A Red Hat OpenShift Container Platform route exposes a service at a host name, so that external clients can reach it by name. When you created the platform gateway instance, a route was created for it. The route inherits the name that you assigned to the platform gateway object in the YAML file.
About this task Copy linkLink copied!
Procedure Copy linkLink copied!
oc get routes -n <platform_namespace>
Results Copy linkLink copied!
You can see in the following example, the example platform gateway is running in the ansible-automation-platform namespace.
$ oc get routes -n ansible-automation-platform
NAME HOST/PORT PATH SERVICES PORT TERMINATION WILDCARD
example example-ansible-automation-platform.apps-crc.testing example-service http edge/Redirect None
The address for the platform gateway instance is example-ansible-automation-platform.apps-crc.testing.
Fetch the platform gateway password Copy linkLink copied!
The YAML block for the platform gateway instance in the AnsibleAutomationPlatform object assigns values to the name and admin_user keys.
About this task Copy linkLink copied!
Procedure Copy linkLink copied!
Decode the platform gateway password Copy linkLink copied!
After you have fetched your gateway password, you must decode it from base64.
About this task Copy linkLink copied!
Procedure Copy linkLink copied!
oc get secret/example-admin-password -o jsonpath={.data.password} | base64 --decode