network automation blog

  • Ansible Builder intro

    Ansible Builder is a Python tool used to build execution environments for AAP/AWX. An execution environment is a container acting as the Ansible Controller Node and is a required component in AAP/AWX. To get started, install Ansible Builder with pip, and make sure you have Podman/Docker installed, as Ansible Builder depends on a containerization tool.…

  • Workflow thoughts

    My workflow is centered around the terminal where my main drivers are bash, tmux, and neovim. A lot of time has been invested into this workflow by exploring, writing, and optimizing dotfiles and key bindings. The result of this investment is a keyboard-driven workflow that requires very little mental overhead while also providing familiar ground…

  • Installing Ansible correctly

    The Ansible controller requires a UNIX-based OS and Python. Since Ansible runs in Python, it can (and should) be installed through pip – the package manager for Python. The optimal way to manage Python packages is by first creating and enabling a virtual environment; a disposable and OS-isolated environment locked to a specific Python interpreter.…

  • Ansible inventory structure

    The inventory is Ansible’s source of truth. It is where all your hosts and groups, along with data like NTP and VLANs, are defined. Building and maintaining an inventory for Ansible can be difficult, but less so if you get the structure right. I define my groups and hosts in a (ini) file named groups_and_hosts.…

  • Kinesis Advantage360 review

    Kinesis Advantage360 is a split keyboard focusing on ergonomics. I started using it due to a wrist injury, and I’m almost glad I got injured because it led me to this keyboard. It took me around 3 months to get comfortable typing on this keyboard. If you, like me, never learned proper touch typing –…

  • Ansible loop speed to the max

    Imagen you want to use Ansible to set interface description based on CDP. The following example is super slow because each iteration in the loop, that satisfies the condition, is a separate task that Ansible has to execute. Modern modules, so-called resource modules, start with a “config” option that accepts multiple items from a list.…

  • Cisco Catalyst slow SCP fix

    Cisco released the following command in IOS-XE 17.2.6. This essentially increases the window-size for SCP which allows for more throughput – and it is very noticeable: an IOS-XE image is around 1.2 GB, and this new command makes SCP go from hours to minutes. Here is an Ansible example showing how to utilize this new…

  • Ansible persistent logging

    By default, Ansible logs the output of playbooks to stdout. This is all fun and games until you close the terminal, something breaks, your logs are gone and you (like me) don’t remember exactly what you did. Luckily, persistent logging can easily be configured on the Ansible controller. These logs do not give you the…