nornir-filtering-demo
Python 3.8
Python 3.9
Code Style

Nornir 3 Filtering Demo

This repository contains a set of examples and use-cases using nornir filtering.

Table of Contents

Installation

In order to use the demo, please follow the installation instructions below:

  1. Create the virtual environment to run the application in:
virtualenv --python=`which python3` venv
source venv/bin/activate
  1. Install the requirements:
pip install -r requirements.txt

Structure

The demos provided in this repository are provided as "canned demos".

That is, all commands, requirements and dependencies are contained inside each folder.

The demos work their way up in terms of complexity and depth of use-cases and are intended to be followed in the order that is shown below:

Level Description
001-basic Basic nornir filtering using one-dimensional filters
002-intermediate Intermediate nornir filtering using multi-dimensional filters
003-advanced Advanced filtering using the F filter, filter functions and "chained" filters

In addition to this, each demo contains all the code of the previous demo, so you can compare functions and see the differences.

For example, 003-advanced will contain all code from the 001-basic and 002-intermediate demos.

Videos

To watch all three demos, including explanations, please watch the video below:

nornir - Filtering Deep Dive

Reference Documentation

Below are some links to other resources which you might find of assistance:

Nornir - Offical Documentation - Filtering the inventory

Filtering Cheatsheet

See the CHEATSHEET

View code on GitHub
  • Owner

  • Contributors

    +2Github contributors
  • Categories

  • Programming Languages

    Makefile
  • License

    MIT License

Code Exchange Community

Get help, share code, and collaborate with other developers in the Code Exchange community.View Community
Disclaimer:
Cisco provides Code Exchange for convenience and informational purposes only, with no support of any kind. This page contains information and links from third-party websites that are governed by their own separate terms. Reference to a project or contributor on this page does not imply any affiliation with or endorsement by Cisco.