Advanced Network Automation with Ansible

Overview

This course covers advanced networking automation with Ansible looking at how to structure projects that have complexity in size and scale (or unique configuration on one-off devices) as well as how to extend Ansible by creating custom modules, custom Jinja2 filters, and custom variable plug-ins.

Note: This is a three (3) day course.

Prerequisites

  • 6-12+ months using Ansible or our Network Programming & Automation course
  • 6-12+ months using Python or our Network Programming & Automation course
  • Good grasp on networking concepts such as device configuration of interfaces, VLAN, OSPF, and BGP.
  • Feel comfortable using Linux to use Ansible and write Python scripts
  • Have a text editor of choice you prefer to use when developing in Python

 

Course Summary

Module 1 – Reviewing Ansible Playbooks and Project Structure

Module 2 – Writing Custom Jinja2 Filters

Module 3 – Writing Custom Ansible Modules

Module 4 – Writing Custom Vars Plugins

 

Course Outline

Module 1 – Reviewing Ansible Playbooks and Project Structure

In this module, we’ll review lessons we’ve learned from deploying Ansible in production environments.  Consider these the do’s and don’t’s of using Ansible for network automation.  We’ll review common patterns, the use of roles, general abstractions, project structure, and even how to handle one-off configurations (because they still exist) when using Ansible.

This module starts on Day 1 and finishes on Day 2.

Module 2 – Writing Custom Jinja2 Filters

Ansible ships with dozens of built-in Jinja2 filters that are extremely valuable to be aware of.  We’ll review a few of them, but more importantly, show how to create and use custom Jinja2 filters that provide for writing simpler playbooks and simpler Jinja2 templates in the context of network automation.

This module is on Day 2.

Module 3 – Writing Custom Ansible Modules

Just like Module 2, Ansible ships with 100s of network modules.  However, you may have a unique network device or internal custom system (IPAM as an example) and it could be in your best interest to write and use custom modules simplfying playbooks.  We’ll review how to write modules ensuring they are idempotent even for custom tasks/modules.

This module is on Day 3.

Module 4 – Writing Custom Vars Plugins

There are particular network use cases that are solved by using Ansible as-is, but potentially make things a little more complex and tedious than they need to be.  This module walks through those use cases and showcases how to create custom vars plug-ins.

This module is on Day 3.

 

Major Points:

  • This is a three (3) day course.
  • Class hours still start at 9am and run until about 5:00pm.  Final day usually ends a few hours earlier.
  • This course will use a combination of the following device types: Cisco NX-OS, Cisco IOS, and Arista EOS.
  • Each student will have their own dedicated pod with at least 6 network devices
  • Private boot camps available upon request.
  • This course has over 65% hands-on labs