SevOne

SevOne

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only

Execute different Ansible Playbooks based on logic and ServiceNow integration 

Thu April 04, 2024 04:58 AM

Description:  The workflow runs the Ansible playbook natively from RNA itself.  The workflow captures and parses the results of the Ansible playbook.  In this scenario, the Ansible playbook has a task to query the status of Ethernet interface eth1 on a VYOS router.  If the status of the interface is down, a Service Now ticket is opened and the output of the Ansible playbook is inserted in the details field of the SNOW ticket.  If the status of the interface is up, an additional playbook is executed to get the “ARP” table for the interface.

List of requirements:

RNA Version: 2024.1.497 or later

ServiceNow:  Developer Version

Environment Required:

·        RNA:  needed to get a list of network devices

·        ServiceNow: Developer instance that will be used to open service incidents

Inputs:

  • VYOS router IP address
  • Interface to query
  • Service Now instance login information

Setup:

  • Workflow: Executes the Ansible playbook. 
  • Workflow: Parse the output and look for the status of the ethernet interface.
  • Workflow:  If the interface is DOWN, login to Service Now and open a new incident.
  • Workflow:  If the interface is UP, an additional ansible playbook is executed to gather the ARP status of the interface.

Instructions:

To Run the Workflow: 

·        Execute the workflow.

Expected results:

A message indicating the status of the interface is shown and ARP table information if the Interface is in UP state.

High-Level Workflow Overview

Statistics
0 Favorited
15 Views
1 Files
0 Shares
3 Downloads
Attachment(s)
zip file
RNA_AnsibleModule_Playbook_2024-04-03_17_49_17.zip   1 KB   1 version
Uploaded - Thu April 04, 2024