Data Models
Let's learn about data models and their role in the automation process.
We'll cover the following
What are data models?
Data models are structured, human-readable, and intent-based text files. They are also known as data dictionaries and hold the variables leveraged by dynamic templates. These models become the source of truth, and network devices are configured to the desired state based on intent. Data models are written in YAML format.
For the most part, key-value pairs and lists make up a data model. There are both group and host variables that apply to a collection of devices or an individual device on the network. As modeling data is a key component of network automation, considerable time and care should be spent creating it. Thus, it is not common to refactor a model multiple times before finding the most effective way to handle data that can scale.
Sample data model
Here is a sample data model, in YAML format, for a campus access switch:
Get hands-on with 1400+ tech skills courses.