Skip to main content
  1. Tags/

ansible

2023


2023 Automation Review: Top 3

·542 words·3 mins
The year of 2023 I think may have had some of the biggest leaps in the Network Automation capabilities that are being delivered by some of the best in the business. With Nautobot’s Golden Config App adding the ability to complete configuration remediation and Ansible release Event Driven Ansible, there are a couple of powerful tools to help you with your Network Automation. And all with a great new conference addition specific to Network Automation.

Nautobot: Get IP Addresses From Nautobot

·1979 words·10 mins
One of Nautobot’s primary functions is to serve as an IPAM solution. Within that realm, the application needs to provide a method to get at IP address data for a device, quickly and easily. In this post I will review three prominent methods to get an IP address from Nautobot. It will demonstrate getting the address via: Nautobot REST API curl Python Requests GoLang HTTP pynautobot Ansible Lookup Nautobot GraphQL API curl Python Requests GoLang HTTP pynautobot Ansible Lookup Each method I will demonstrate how to get the IP address for Loopback0 on the device bre01-edge-01 within the demo instance of Nautobot.

Nautobot IP Provisioning

·1390 words·7 mins
One of the great things about building an enterprise system, is being able to get systems to work cohesively amongst themselves to bring a complete solution. One of the workflows that is often required in a static IP address environment is the need to provide static IP addresses to hosts on a network segment. When using an IPAM (IP Address Management) solution such as Nautobot, the APIs and SDKs/modules made available for use in automation workflows is paramount to having the cohesion to make a seamless IT system.

2022


Automation Inventory

·710 words·4 mins
This is a topic that I’m fairly opinionated on as of late is looking at what should be maintained within an inventory and the strategy of how to set up the inventory. For the case of this blog post, I am going to use the term playbook to represent the automation being run. This is yes an Ansible term, but also apply this as your automation run that is using Nornir or any other automation framework.

2021


Nautobot Ansible Collection: Devices

·1657 words·8 mins
All of the work through the modules thus far in the series have brought us to what we all want to see. How to get or update device information inside of Nautobot. Adding of sites, device types, device roles are required to get us to this point. Now you can see how to add a device to Nautobot using the networktocode.nautobot.device module. There are many optional parameters for the module specifically.

Nautobot Ansible Collection: Device Types

·1722 words·9 mins
A device type is the next piece in the Nautobot Device onboarding requirements. The device type corresponds to the model number of the hardware (or virtual machine). This is where you are able to template out devices during their creation. So if you have a console port on a device type, that console port will be created when you create the device. However, there is NOT a relationship built between the device type and the device.

Nautobot Ansible Collection: Device Roles

·1112 words·6 mins
A device role is aptly named, the role of the device. This is likely to be something that is meaningful to your organization and could change. For example you may have the 3 tier system of Core, Distribution, and Access layer environments. These are just fine. So you would want to have the roles there to reflect this reality. You may have leaf-spine environments, there are two more roles. And in my past I have also had roles that would indicate that there are dedicated DMZ, WAN edge, Internet edge devices.

Nautobot Ansible Collection: Platforms

·1108 words·6 mins
Platforms are an optional item when adding devices into Nautobot. The platform is the OS that you are going to be using. Most often this is used to help identify which driver your automation platform is going to be using. Specifically the slug of the platform is what needs to match. So in the terms of Ansible (since we are using Ansible to populate Nautobot), you will want to set Cisco IOS devices to ios.

Nautobot Ansible Collection: Manufacturers

·870 words·5 mins
Adding your manufacturers via code is the easy way to get started with your Nautobot devices. Immediately after adding Sites, the next thing to get going when using Nautobot as your Source of Truth is to add in Manufacturers. These are just that, who makes the gear that you use. For this demonstration you will see adding just a few manufacturers. I’m not necessarily picking on any vendors and who should or shouldn’t be here.

Nautobot Ansible Collection: Site Module

·1814 words·9 mins
This post dives into the Nautobot Ansible Content Collection sites module to create/update a Site. This series for the beginning will be a clone of what I had done previously with NetBox. So some of the language will be very similar. When it comes to creating and deleting sites in Nautobot, the question of should I be using Ansible to do this? In my opinion this is a yes it should be.

Nautobot Ansible Collection: Installation

·1203 words·6 mins
This is the first post as I shift into taking a closer look at the Nautobot Ansible Collection. The collection includes many of the needed modules to effectively manage your Nautobot environment. If This will take a deeper dive into several of the components of the inventory plugin, but not all of the options. The documentation for all of the collection can be found at: ReadTheDocs: https://nautobot-ansible.readthedocs.io Galaxy Page: https://galaxy.ansible.com/networktocode/nautobot This post is going to give information on how to install the collection as it may be applicable to every post in the series (as they get posted).

NetBox Ansible Collection: Devices

·953 words·5 mins
All of the work through the modules thus far in the series have brought us to what we all want to see. How to get or update device information inside of NetBox. Adding of sites, device types, device roles are required to get us to this point. Now you can see how to add a device to NetBox using the netbox.netbox.netbox_device module. This post was created when NetBox was an open source project used often in my automation framework.

NetBox Ansible Collection: Device Types

·867 words·5 mins
A device type is the next piece in the NetBox Device onboarding requirements. The device type corresponds to the model number of the hardware (or virtual machine). This is where you are able to template out devices during their creation. So if you have a console port on a device type, that console port will be created when you create the device. However, there is NOT a relationship built between the device type and the device.

NetBox Ansible Collection: Device Roles

·849 words·4 mins
A device role is aptly named, the role of the device. This is likely to be something that is meaningful to your organization and could change. For example you may have the 3 tier system of Core, Distribution, and Access layer environments. These are just fine. So you would want to have the roles there to reflect this reality. You may have leaf-spine environments, there are two more roles. And in my past I have also had roles that would indicate that there are dedicated DMZ, WAN edge, Internet edge devices.

2020


NetBox Ansible Collection: Platforms

·676 words·4 mins
Platforms are an optional item when adding devices into NetBox. The platform is the OS that you are going to be using. Most often this is used to help identify which driver your automation platform is going to be using. Specifically the slug of the platform is what needs to match. So in the terms of Ansible (since we are using Ansible to populate NetBox), you will want to set Cisco IOS devices to ios.

NetBox Ansible Collection: Manufacturers

·473 words·3 mins
Adding your manufacturers via code is the easy way to get started with your NetBox devices. Immediately after adding Sites, the next thing to get going when using NetBox as your Source of Truth is to add in Manufacturers. These are just that, who makes the gear that you use. For this demonstration you will see adding just a few manufacturers. I’m not necessarily picking on any vendors and who should or shouldn’t be here.

NetBox Ansible Collection: Site Module

·1877 words·9 mins
This post dives into the NetBox Ansible Content Collection module to create/update a Site. As I start into this series on looking at the modules that create/update/delete data from NetBox, the question that I keep asking myself is should I be looking at the modules that are creating/updating/deleting items? The reason that I ask this to myself is because I am a firm believer that automation should be coming from NetBox as its Source of Truth (SoT).

NetBox Ansible Collection: Lookup Plugin

·2195 words·11 mins
The NetBox lookup plugin is to get information out of NetBox for use within Ansible. This uses pynetbox to query the NetBox API for the information requested. On top of being helpful in gathering data from NetBox (when it is not your inventory source), but it is extremely helpful in larger NetBox deployments when compared to using the URI module as well. If you wish to use NetBox as your inventory source, you should definitely read my previous post on getting started with the NetBox Inventory Plugin.

NetBox Ansible Collection: Inventory - Starting Out

·1643 words·8 mins
The documentation can be found on ReadTheDocs. This is going to be starting out with the basics of the plugin and getting some sample output and to show how to form groups to be used. This post was created when NetBox was an open source project used often in my automation framework. I have moved on to using Nautobot due to the project vision and providing a methodology that will drive network automation forward further.

NetBox Ansible Collection: Installation

·1154 words·6 mins
This is the first post as I start to look at the NetBox Ansible Collection. This is an impressive collection with modules for several of the NetBox applications, a query plugin, and an inventory plugin. This will take a deeper dive into several of the components of the inventory plugin, but not all of the options. The documentation for all of the collection can be found at: ReadTheDocs: https://netbox-ansible-collection.readthedocs.io/en/latest/ Galaxy Page: https://galaxy.