Defining Ansible AWX Observer jobs
The Ansible AWX observer supports load jobs. When a load job is run, it will gather and read data from an Ansible AWX instance of your choice. When a load job is run, it will load a baseline topology data view from Ansible AWX through its REST APIs.
Before you begin
Important: The Ansible AWX Observer supports the on-premise
Ansible AWX version 21.14.0 and Tower API version 3.8.6.
The Ansible AWX Observer is installed as part of the core installation procedure.
Ensure you have the Ansible AWX details to hand, such as the host, port, user and token before
defining and running the observer job.
Required: Before defining the
observer load job, you must obtain a personal access token (PAT) from AWX. The token authentication
is recommended for the usage of Tower's API.
- From the menu bar, navigate to the Users page that is under the Access section.
- Select a username, then click the Token option.
- Click on the + (plus) icon.
- Leave the application field blank, and choose read for the token’s access.
Remember: Swagger documentation for the observer is available at the following default
location: https://<your
host>/1.0/ansibleawx-observer/swagger
About this task
The Ansible AWX Observer imports ITSM Resource Topology Service data to Agile Service Manager.
ansibleawx_observer_common.sh
- The configuration file you use to customize Ansible AWX Observer settings.
You define and start the following job. You must edit the parameters in the configuration file
before running these jobs.
- Full Topology Upload job
- A transient (one-off) job that loads all requested topology data.
Procedure
To edit the parameters in the configuration file
To start the Load job
Results
The load job loads all requested topology data, and runs only once. Run this job whenever you need Ansible AWX topology data refreshed.
What to do next
You can also use the following scripts:
- ansibleawx_observer_load_stop.sh
- Stops the Load job
- ansibleawx_observer_job_list.sh
- Lists the status of current jobs
- ansibleawx_observer_log_level.sh
- Sets the log level
Remember: As an alternative to being configured using the Observer Configuration
UI, observer jobs have scripts to start and stop all available jobs, to list the status of a current
job, and to set its logging levels. These scripts can be run with -h or
--help to display help information, and with -v or
--verbose to print out the details of the actions performed by the script,
including the full cURL command. For the on-prem version of Agile Service Manager, observer scripts
are configured for specific jobs by editing the script configuration files.