Ansible Automation Platform
Notify team members through Ansible Automation Platform when critical incidents occur.
Supported Versions | Type | Authentication Type |
---|---|---|
<= v2.4 | Webhook | Org Bearer Token |
Ansible Automation Platform with EDA Controller
There are two separate integration tiles for the Ansible Automation Platform. If you are using an EDA Controller, select Ansible Automation Platform with EDA Controller when you install the integration.
Ansible Automation Platform is an enterprise platform used to configure systems, deploy software, and automate repetitive processes across the IT infrastructure.
Ansible Automation Platform replaces manual processes for tasks like cloud provisioning, configuration management, and application deployment using a push-based configuration that automatically sends pre-written configuration files from the Ansible Automation Platform server to the target machine. The target machine then uses the simple configuration file to complete a task without the need to install additional software.
The BigPanda and Ansible integration presents a holistic solution to the challenges faced by IT organizations in their quest for automation. The Integration allows you to lay a solid foundation for intelligent incident management and automation, ultimately enhancing efficiency and lightening the load on your IT teams.
After following the installation steps, you can deploy our certified integration to the Ansible Automation Tower and event-driven automation by following the directions on the Ansible Content Collections page. The Certified BigPanda Collection in Ansible Automation Hub can be found here.
AutoShare Rules
The Ansible Automation Platform integration follows standard AutoShare rules. See the Sharing Rules documentation for more information.
Key Features
- Bi-directional sync - receive constant updates on the state of automation, and update Ansible playbooks when actions occur in BigPanda.
- Resolve alerts or incidents in either system — when resolving in either BigPanda or Ansible Automation Platform, the incidents or individual alerts will be resolved in both systems.
- Update incident tag values - receive incident tag updates in real time from Ansible playbooks.
- Add comments - comments can be added to incidents in BigPanda, keeping you updated on the automation process.
Install the Integration
Administrators can install the integration by following the on-screen instructions in BigPanda.
Custom Headers
BigPanda allows you to create Custom Headers to specify customized information with your integration.
See the Custom Headers documentation for more details. Below are some of the advanced features supported by custom headers.
OAuth 2.0 Support
BigPanda supports OAuth 2.0 with Ansible. In order to add OAuth provider details within the BigPanda Ansible integration, add the following custom headers. Once OAuth details are added, any Basic Auth credentials are ignored when making requests to Ansible.
OAuth 2.0 custom headers apply to both the Ansible Automation Platform (AAP) and the Ansible Automation Platform with EDA Controller (EDA).
Header | Description |
---|---|
x-bp-config-oauthUrl | The URL of the OAuth provider for ServiceNow incident creation. |
x-bp-config-oauthClientId | The client ID for OAuth authentication. |
x-bp-config-oauthClientSecret | The client secret for OAuth authentication. |
x-bp-config-oauthGrantType | The grant type for OAuth authentication. |
x-bp-config-oauthPassword (optional) | Password used for OAuth authentication. This is required only for oauthGrantType of password. |
x-bp-config-oauthUser (optional) | The OAuth user for Ansible. |
x-bp-config-oauthScope (optional) | The OAuth scope for authentication (optional). |
Additional Custom Headers
Unless otherwise specified in the description, these additional custom headers apply to both the Ansible Automation Platform (AAP) and Ansible Automation Platform with EDA Controller (EDA).
Header | Description |
---|---|
x-bp-config-defaultTemplateId | The ID of the job_template to run. |
x-bp-config-ansibleURL | The URL of the Automation Controller or the EDA Controller. |
x-bp-config-ansibleApiToken | The Ansible Automation Platform token. |
x-bp-config-ansibleController | The type of controller being used, either EDA or Automation. |
x-bp-config-automateIndividualAlerts | When set to true, it sends a request for every single alert in an incident. For this header, you need to set the x-bp-config-alertTemplateIdTagname. This applies only to AAP |
x-bp-config-alertTemplateIdTagname | Used in AAP with automateIndividualAlerts to allow the AAP controller to trigger automation based on a tag from an alert. This applies only to AAP. |
x-bp-config-ansibleOverrideURL | An override sent to another service for handling before triggering an Ansible automation. |
BigPanda Ansible Collection
Using and Developing the BigPanda Ansible Collection
To use and develop with the BigPanda Ansible Collection, follow these steps:
- Run the following commands to build and install the collection in the ./collections folder. You will need to perform this step whenever you make changes:
ansible-galaxy collection build --force
ansible-galaxy collection install bigpanda-incident-<VERSION>.tar.gz -p ./collections -f
- Run the Ansible playbook for testing. Replace the placeholders with your specific information:
ansible-playbook ./bigpanda_test.yml --extra-vars='{"environment_id": "YOUR-ENV-ID","api_token": "YOUR-API-TOKEN", "incident_id":"YOUR-INCIDENT-ID", "tag_id": "test", "tag_value": "success"}'
Running in an Instance
To run in an instance, you'll need to create a decision environment for Event-Driven Automation (EDA) and/or an execution environment for Ansible Automation Platform (AAP). Follow these guides:
These guides will help you set up the necessary environments for BigPanda Ansible Collection.
Responding to BigPanda Events
BigPanda sends a variety of event types depending on what happens within a BigPanda incident. We recommend configuring Ansible playbooks to trigger based on the most recent event_type included in the array of events. For more information, see the data schema.
incident#become-flapping
incident#reopen
incident#closed
incident#updated
incident#new
incident#commented
incident#snoozed
incident-tag#upserted
incident#ticket-sync
Share Update Delay
By default, the incident#ticket-sync event sends incident updates every 2.5 minutes to prevent spamming target systems with updates. To lower this, contact BigPanda Support and request a lower share update delay setting (typically 5 or 10 seconds is advised). This event type will be deprecated with the rollout of BigPanda's Delayed Autoshare feature.
Action Modules
The BigPanda Ansible Collection provides various action modules to interact with the BigPanda resource management system. These modules allow you to perform operations such as resolving incidents, resolving alerts, adding comments to incidents, and updating incident tags.
To use these action modules, include them in your Ansible playbook and provide the required parameters for the specific function you want to execute.
Resolve an Incident
Use the bigpanda.incident.resolve action module to resolve an incident by providing the incident ID and a resolution message.
Parameters:
- incident_id (required): The ID of the incident to resolve.
- resolution_comment (optional): The resolution message for the incident.
- api_token (required): The API token for authentication.
- name: Resolve Incident
bigpanda.incident.resolve:
incident_id: <incident_id>
resolution_comment: <resolution_comment>
api_token: <api_token>
Resolve Alerts
The bigpanda.incident.resolveAlerts module allows you to resolve an alert by providing the alert ID and resolution message.
Parameters:
- alert_ids (required): The ID of the alert to resolve.
- resolution (optional): The resolution message for the alert.
- api_token (required): The API token for authentication.
- name: Resolve Alert
bigpanda.incident.resolveAlert:
alert_ids: <alert_id>
resolution: <resolution>
api_token: <api_token>
Add a Comment to an Incident
You can add a comment to an incident using the bigpanda.incident.comment module. Provide the incident ID and the comment text.
Parameters:
- incident_id (required): The ID of the incident to add a comment to.
- comment (required): The text of the comment.
- api_token (required): The API token for authentication.
- name: Add Comment to Incident
bigpanda.incident.comment:
incident_id: <incident_id>
comment: <comment>
api_token: <api_token>
Update Incident Tag
Use the bigpanda.incident.updateIncidentTag module to update an incident tag. Provide the tag ID, tag value, incident ID, and API token.
Parameters:
- tag_id (required): The ID of the tag to update.
- tag_value (required): The new value for the tag.
- incident_id (required): The ID of the incident to update.
- api_token (required): The API token for authentication.
- name: Update Incident Tag
bigpanda.incident.updateIncidentTag:
tag_id: <tag_id>
tag_value: <tag_value>
incident_id: <incident_id>
api_token: <api_token>
Uninstall the Integration
Deleting an integration requires changes to both the integrated system and BigPanda. You must uninstall the integration on the integrated system and then delete the integration from BigPanda.
When replacing an existing integration with a new tool or system, we recommend configuring the new integration first to ensure no data is lost.
Stop Sending Data from BigPanda
In BigPanda, disable any settings that send data to the integrated system. This includes modifying or removing AutoShare rules or Environments that are tied to the integration.
Delete the Integration from BigPanda
- In BigPanda, navigate to the Integrations tab and select the desired integration from the list.
- In the integration details on the right of the page, click the trash icon, then confirm you want to delete the integration. The integration will then be removed immediately.
️Data Removal
This procedure does not remove any data from BigPanda or the integrated system. As needed, remove data from each system before deleting the integration.
Updated 6 months ago