Automating Network Design in NVIDIA Air with Ansible and Git - 夜莺博客

Automating Network Design in NVIDIA Air with Ansible and Git

NVIDIA Air is a free cloud-based network simulation platform where every part of the network — topology, config, validation — can be coded, versioned and automated. The intended workflow is Infrastructure as Code: store your switch configs in Git, deploy them with Ansible from the built-in management server, and validate the result. This article explains the building blocks: why manual CLI config does not scale, what goes into your inventory and playbooks, and how to use the oob-mgmt-server as the automation jumpbox.

Why Manual Configuration Does Not Scale

Bringing up a simple CLOS network — one spine, two Cumulus Linux or SONiC leaves, two Ubuntu servers — takes a hundred or so CLI commands. Multiply that by 10, 50 or 100 nodes and it is simply not feasible by hand. The fix is to treat configuration as data: store it in files (NVUE YAML for Cumulus Linux, config_db.json for SONiC, FRR configs, ZTP scripts) and apply it automatically.

Version Control with Git

GitLab or GitHub is the recommended external home for your configuration files — most NVIDIA Air demo simulations store their configs in a Git repo. You keep full version history and rollback ability while treating the simulated network exactly like a physical one.

Ansible for Deployment and Validation

Ansible is agentless — it connects over SSH, needs no daemons or databases, and lets you deploy configuration to different operating systems in the same network from one playbook run:

ansible-playbook -i {inventory} playbooks/{playbook}

You define managed nodes and credentials in an inventory file and automation steps in YAML playbooks.

The oob-mgmt-server Jumpbox

Every NVIDIA Air simulation with the out-of-band management network enabled gets an oob-mgmt-server Ubuntu node. It is connected to all other nodes on the OOB network, has a built-in outbound connection, and comes with Ansible and Git preinstalled — the ideal place to run your playbooks. Copy your scripts and configs in via scp (which also mimics the file-transfer workflow of a real air-gapped environment), then run the playbook from there.

Getting started is free at air.nvidia.com — try the Cumulus Linux Workshop or SONiC Workshop labs for a guided walkthrough. See also Ansible 网络自动化完全指南 and SONiC 安装与配置 for more automation and SONiC context.

原文链接:https://developer.nvidia.com/blog/automating-network-design-in-nvidia-air-with-ansible-and-git/