Avatar

Catalyst Center Templates published

Overview

Catalyst Center is maturing into a very robust tool for the network administrator. The lessons learned over a decade from Prime guided us toward a tool that will transform the future of networks. Prime has served many organizations for over a decade; Catalyst Centers’ capabilities and unique UI make it a robust successor. Additionally, Catalyst Center can easily accomplish various network automation tasks that would ordinarily take days to achieve. Lastly, to aid in understanding Catalyst Center’s capabilities, we provide a helpful Catalyst Center template tutorial.

Secondly, an area where Catalyst Center excels is in the area of automation. Catalyst Center uses a simple hierarchical workflow mechanism that enables the deployment of network settings, credentials, images, and templates to the network. Catalyst Center’s hierarchical approach to intent automates and provides policy continuity. 

Finally, many will probably find the whole prospect of change and the development of automation templates a daunting task. It may seem cumbersome to revisit today’s methods to build configurations. As a result, reviewing their construction and changing their deployment approach may feel a little overwhelming. 

In this ongoing Catalyst Center Automation Series, our focus is on using multiple approaches to automating the network. This will help enable you, the network administrator, with the capability to solve more types of configuration issues from Catalyst Center and to deal with the dynamics of an enterprise network.

Within this series, we cover the following;

  1. PnP Preparation – explains the overall Plug and Play set up steps
  2. Onboarding Templates – explains in-depth how to deploy Day 0 templates
  3. Day N Templates – dives into Day N template constructs with both regular and composite templates and use cases
  4. Application Policys – explores Application Policys and SD-AVC in Catalyst Center and their use
  5. Telemetry – explains how to deploy Telemetry for assurance
  6. Advanced Automation – explores Advanced Automation techniques
  7. Dynamic Automation – a deployment lab for dynamic automation

How?

To aid customers in the transition toward automation, we have put together a set of small helpful tutorials within a Github repository. As a result, we hope to demystify some of the complexities of setting up plug-and-play and help guide customers through the complexities. In this way, the tutorial provides a glimpse into the fundamentals of building Velocity and Jinja2 templates and provides examples that you can download and expand from. These sample templates and JSON files are supplied for easy import into Catalyst Centers’ template editor for quicker adoption.

Firstly, we delve into the concepts of building templates and methodologies for using both Onboarding and DayN templates at length. Secondly, answers to many of the questions that come up during automation workshops are explained. The hope is that you find the information both helpful and informative. Thus, information is included, which will hopefully give a well-rounded explanation of automation methods and concepts.

The DNAC-TEMPLATES repository includes tutorials, scripts and samples of:

  • Velocity Scripting
  • Jinja2 Scripting
  • Variables
  • Binding Variables
  • Composite Templates

These samples build a tutorial that aims to be a practical guide to aid engineers to rapidly begin using Catalyst Center automation and help them work towards a template strategy. This will enable engineers to reduce the time and effort needed to instantiate the network.

As a result, the tutorial also does an in-depth flyby about setting up Plug and Play onboarding and templates. Additionally, it has a section on advanced Velocity and Jinja2 templating and troubleshooting tools which may help during faultfinding to determine what is failing in a deployment.

In order to keep this repository relevant, new content is added frequently to the repository DNAC-TEMPLATES, so stay tuned…

Furthermore, the repository is also directly available from Github at DNAC-TEMPLATES.

Intent-Based Networking

To deploy Intent, we use combinations of either one or multiple templates and the Design Settings and Policies within the UI. Lastly, Day N methods allow for one or multiple templates by using composite templates that combine many regular templates into one logical flow.

Additionally:

  1. Intent is a combination of configuration templates, configuration, policy, code, and settings.
  2. Logical constructs modify or choose between various results via decision (‘IF’) statements.
  3. Looping structures within the template allow for repetition of configuration
  4. Variables may be used when the device is being onboarded or provisioned

Tutorial Sections

Various sections will be covered within this github repository. Please use this menu as the main index for navigating content. You will find various examples within the various folders of this repository, with supplied explanation readme files for reference.

Tasks

  • PnP Onboarding – This section explains the overall Plug and Play Methodology
  • Onboarding Templates – This section will explain Onboarding Templates in Cisco Catalyst Center and their use in bringing various devices under Cisco Catalyst Center management
  • DayN Templates – This section will explain how to use templates for ongoing (Day-N) changes to the network

Templating

  • Building Templates – This section will explain how to build a template on Cisco Catalyst Center from scratch

Velocity Language

  • Velocity Variables – This section explains Template Variables in depth, and how and where to use them
  • Velocity Scripting – This section will dive into Velocity Language Template Scripting constructs and use cases
  • Advanced Velocity Scripting – This section will dive into Advanced Velocity Language Template examples

Jinja2 Language

  • Jinja2 Variables – This section explains Template Variables in depth, and how and where to use them
  • Jinja2 Scripting – This section will dive into Jinja2 Language Template Scripting constructs and use cases
  • Advanced Jinja2 Scripting – This section will dive into Advanced Jinja2 Language Template examples

Advanced Use Cases

  • Embedded Event Manager – This section will dive into EEM (Embedded Event Manager) Scripting and various use cases
  • System Variables – This section explains Cisco Catalyst Centers System Variables

Orchestration of Cisco Catalyst Center

  • REST API Orchestration – This section is a high level discussion of utlilizing REST API with Cisco Catalyst Center
  • Python Orchestration – This section is a high level discussion of utilizing Python with Cisco Catalyst Center
  • Ansible Orchestration – This section is a high level discussion of Ansible orchestration of Cisco Catalyst Center
  • CICD Orchestration – This section is a high level discussion of CICD orchestration of Cisco Catalyst Center

Fault-Finding

  • Troubleshooting – This section will dive into Troubleshooting Velocity based Template Constructs
Note: These sections build on the concepts mentioned in posts written by Adam Radford, a Distinguished System Engineer. Adam’s selection of posts can be found by following this link to blogs on cisco.com.

Catalyst Center Labs

This section built out in a lab format to guide you through the typical steps to complete various automation tasks delivered by Cisco Catalyst Center. It allows for customers to practice Cisco Catalyst Center workflows with Onboarding, DayN Templates, and Application Policy automation on both Wired and Wireless Platforms, while reducing the time and effort needed to instantiate the network The lab will also introduce advanced velocity templating topics and troubleshooting tools, which may help determine common failure scenarios in a deployment.

To help customers succeed with Cisco Catalyst Center automation, you may utilize the above labs as they have been designed to work within DCLOUD’s Cisco Enterprise Networks Hardware Sandbox Labs in either:

  1. Cisco Enterprise Networks Hardware Sandbox West DC
  2. Cisco Enterprise Networks Hardware Sandbox East DC

New Catalyst Center Lab Content

Please use this menu to navigate the various sections of this GitHub repository. Within the multiple folders are examples and explanation readme files for reference. There are now two sets of labs, and these are being continually expanded upon.

This newer and more modular lab approach is designed to deal with and includes concepts from the legacy labs in a newer more modular format.

  1. Lab 1 Wired Automation – Covers green and brown field use cases (allow 4.0 hrs)
  2. Lab 2 Wireless Automation – Covers traditional wireless automation (allow 4.0 hrs)
  3. Lab 4 Rest-API Orchestration – Covers automation of Cisco Catalyst Center via Postman with Rest-API (allow 2.0 hrs)
  4. Lab 7 CICD Orchestration – Covers Python with JENKINS orchestration via REST-API (allow 4.0 hrs)

We will share additional labs and content in an ongoing effort to fulfill all your automation needs with Catalyst Center.

Examples

When building the template you will need to select a scripting language. Specific examples of Templates in the two scripting languages supported are available in sub folders within the following folders:

The conditions that they are used are documented and are explained in Onboarding Templates and examples of DayN Templates are explained in DayN Templates

These examples must be used with two conditions:

In conclusion, if you found this repository or any section helpful, please fill in comments and feedback on how it could be improved.


We’d love to hear what you think. Ask a question or leave a comment below.
And stay connected with Cisco DevNet on social!

Twitter @CiscoDevNet | Facebook | LinkedIn

Visit the new Developer Video Channel



Authors

Keith Baldwin

Solutions Engineer

Campus Automation CoE for Enterprise Networking