Network Automation     Archive

Guest Blog! Dynamic Surveys Sort of....

This post is guest blogged by Eric, a good friend and fellow Red Hatter. For folks who may not know him:

Eric currently holds 2 Masters Degrees in Network and Information Technology as well as an MBA from the University of Massachusetts Lowell. He also holds and has held various industry certifications from CCNP to Red Hat Architect. He has worked in many different fields throughout his career from Networking, Virtualization and Cloud. He has helped build the Network Automation Practice for Ansible within Red Hat and continues to grow as he is now working on all aspects of Ansible and ACM as well as moving toward Openshift Container Platform.

In this blog post he addresses a question that he’s been asked about by many organizations - the need for Dynamic Surveys in Ansible Tower. This feature would allow them to branch off on the fly as needed as well as populate items that have just been added. This blog will show you how to populate new items into surveys without having to do it by hand everytime the file changes. This could be do to for example a new OCP cluster being added or network interface being turned up and ready for use and populated in the troubleshooting field option of a lower Tier team members playbook access. Another example is if a new VMWare vCluster is added and it needs to be added as a choice for creating new vm’s within.

Read more

The idea of a "CareTaker" for git centeric network operations

Many organizations have embraced, or are beginning to embrace the configuration management of their network devices through code. A common pattern that I’ve come across consists of:

  1. A git repository for scrubbed, last-known-good-configs
  2. Another git repository that holds the infrastructure as code (IaC)

Operators create feature branches off of the second repo, and submit pull-requests. These changes are then subject to various tests (manual or automatic) before being approved and merged into the master branch, which then gets deployed onto the end points.

But the idea of GitOps goes further than that – it uses tools to compare the actual production state of your endpoints with what’s under source control and then it tells you when they don’t match. This post introduces the idea of a “CareTaker” that detects out-of-band (OOB) changes made to the network endpoints and alerts the operator to make a manual decision.

Read more

Cleaning up pending Tower Jobs

This post is a quick troubleshooting gist based on a recent problem I encountered. I had an external system make API calls to Ansible Tower and trigger a job template. Pretty standard stuff…however, the configuration on the remote system was, ummm, not very accurate and I ended up with a ton of API calls to my Tower machine.

Read more

Ansible Custom Inventory Plugin - a hands-on, quick start guide

This post shows you how to write a custom inventory plugin for Ansible. As usual, this is not a deep dive. If you are interested about what inventory plugins are or why you might want to use them. Please see the Ansible docs. Additionally for an in-depth understanding of inventories in general and inventory plugins in particular I highly recommend these videos:

  1. Ansible inventory for fun and profit by @Matt Davis
  2. Managing Meaningful Inventories by @Will Tome and @Alan Rominger

Finally, this post describes my workflow while building custom inventory plugins. This post is better consumed as a “do-it-along”.

Read more

Custom credentials in Ansible Tower to store Github private keys

This post shows you how to add a custom credential in Ansible Tower, that stores SSH private keys. I won’t dive into what custom credentials are and how to get started with them because it is brilliantly covered in this “Inside Playbook” by @bill_nottingham

Read more