Integrating Ansible with Service-Now
C o re y Wa n l e s s S e n i o r S y s te m s A d m i n i s t ra t o r
@WWT since Jan 2017
Previously from Mercy and Caterpillar
Storage Administration background
With Focus on Infrastructure Automation
Fun Fact:
I have a hard time picking out cereal
Corey Wanless
Senior Systems Administrator
Agenda
• What is Tower?
• What is Service-Now?
• Our Problem
• Our Approach
• Explore the Tower API
Tower
• Centralizes Ansible Projects
• Wraps your Ansible Playbooks and Inventories in a web
service
• Features:
• Playbook Execution (Job Templates)
• Source Control Integration (Projects)
• Credential Management
• Scheduling
• Inventory Management (Dynamic and Static)
• RBAC
• Rest API
• AWX is the upstream version while Tower is Redhat’s
Enterprise Supported version.
Service-Now Do we really need to talk
about this?
Our Problem
• Large need for self-service in IT Organization
• Sizable learning curve to develop in Service-Now
• Small Service-Now Development team.
Our Approach
• Abstract for re-use and scale
• Templatize as much as possible
• Document for others.
• Allow for flexibility
• Assume there will be failures
• Ensure there was 2-way
communication
General Flow
of the Core
Workflow
• Required API Endpoints:
• /api/v2/job_templates?name=<name>
• /api/v2/job_templates/<job_template_id>/launch/
• /api/v2/jobs/<job_id>
• /api/v2/jobs/<job_id>/stdout
Templated
Workflow
• Developer only needs to
update what’s in the
orange
Fast Forward to No..
Request Count in Jan
Tableau Access 301
Provision O365 User 213
Mailbox Access 102
VPN Access 65
Oracle Database Access 59
Reset Admin Password 56
VPN Pin Reset 41

Ansible meetup - Service-Now Integration

  • 1.
    Integrating Ansible withService-Now C o re y Wa n l e s s S e n i o r S y s te m s A d m i n i s t ra t o r
  • 2.
    @WWT since Jan2017 Previously from Mercy and Caterpillar Storage Administration background With Focus on Infrastructure Automation Fun Fact: I have a hard time picking out cereal Corey Wanless Senior Systems Administrator
  • 3.
    Agenda • What isTower? • What is Service-Now? • Our Problem • Our Approach • Explore the Tower API
  • 4.
    Tower • Centralizes AnsibleProjects • Wraps your Ansible Playbooks and Inventories in a web service • Features: • Playbook Execution (Job Templates) • Source Control Integration (Projects) • Credential Management • Scheduling • Inventory Management (Dynamic and Static) • RBAC • Rest API • AWX is the upstream version while Tower is Redhat’s Enterprise Supported version.
  • 5.
    Service-Now Do wereally need to talk about this?
  • 6.
    Our Problem • Largeneed for self-service in IT Organization • Sizable learning curve to develop in Service-Now • Small Service-Now Development team.
  • 7.
    Our Approach • Abstractfor re-use and scale • Templatize as much as possible • Document for others. • Allow for flexibility • Assume there will be failures • Ensure there was 2-way communication
  • 8.
    General Flow of theCore Workflow • Required API Endpoints: • /api/v2/job_templates?name=<name> • /api/v2/job_templates/<job_template_id>/launch/ • /api/v2/jobs/<job_id> • /api/v2/jobs/<job_id>/stdout
  • 9.
    Templated Workflow • Developer onlyneeds to update what’s in the orange
  • 10.
    Fast Forward toNo.. Request Count in Jan Tableau Access 301 Provision O365 User 213 Mailbox Access 102 VPN Access 65 Oracle Database Access 59 Reset Admin Password 56 VPN Pin Reset 41

Editor's Notes

  • #6 - It is a cloud hosted ITSM tool - It has about 40% of the ITSM space. - Along with Incident / Change / Request / Asset Management, they have a bunch of other modules. One of those modules is workflow and the self-service portal.
  • #7 Self Service Requirements Need approval processes End User access to Tower would be sloppy and not easy for the user. Form Capabilities in Tower are severely limited Learning Curve Need to have a strong understanding of Javascript. Need to understand Service-Now best practices Need to understand WWT’s implementation best practices. Small Development Team Focused not only on the ITSM needs of our IT org, but also components made for the business: Facility Management Asset Management of ATC HR Integrations Release Management
  • #8 Abstraction There are things in the Tower API that are ID driven and not an input a human will want to try and keep straight. IE when you POST against objects, you are doing so against their ID not their name. Not to mention, the ID’s will change between your Tower instances. A layers of abstraction allows us to make global changes to the platform without having to touch every automation. Templatize Service-Now has plenty of ‘Copy’ functions. Use them to your advantage! Document Remember we were trying to make it so that anyone can in the organization can pick this up and run with it. This means we needed to have reliable documentation!