Networking Security
Network Automation
Automating network configuration and checks with scripts, APIs and tools.
- 28 notes
- 219 minutes of reading
- Network automation: why automate, the toolchain and model-driven APIsWhy manual configuration doesn’t scale, the benefits of automation, the automation stack, how tools talk to devices (SSH, NETCONF, RESTCONF, gNMI, REST), YANG, YAML and JSON, sources of truth and idempotency. 8 min · Intermediate
- Python for network engineers: libraries and a first automation scriptWhy Python is the language of network automation, the key libraries (Netmiko, NAPALM, ncclient, requests, Nornir, TextFSM), a complete configuration backup script with a YAML inventory, safe changes and a learning path. 9 min · Intermediate
- Ansible and NetDevOps: playbooks, inventories and CI/CD for networksWhy Ansible suits network teams, inventories and variables, an idempotent VLAN playbook using Cisco IOS modules, check mode, protecting secrets, and how Git, reviews and CI/CD pipelines make network changes safer. 9 min · Advanced
- Automating the network lifecycle: discovery, zero-touch provisioning, upgrades and decommissioningHow automation applies across a device's whole life: discovering what is on the network, zero-touch provisioning of new switches and routers with DHCP, templates and standard profiles, safe automated software upgrades, and clean decommissioning. 9 min · Intermediate
- Planning network automation: benefits, risks, skills and a staged roadmapHow to introduce network automation in a real team: the benefits you can expect, the drawbacks and barriers (skills, cost, culture), the difference between automation, orchestration and programmability, a staged roadmap and how to measure success. 8 min · Beginner
- Data formats, YANG models and device programmability: NETCONF, RESTCONF and gNMIWhy the CLI and SNMP are awkward for automation, the data formats you will meet (XML, JSON and YAML), what a YANG data model is, and how NETCONF, RESTCONF and gNMI/gRPC let software read and change device configuration and stream telemetry. 10 min · Intermediate
- REST APIs for network engineers: resources, CRUD, status codes and authenticationWhat a REST API is and why network controllers and cloud platforms use them, how CRUD maps to HTTP methods, how to read status codes and JSON responses, and the common ways APIs authenticate you: basic authentication, API keys, tokens and OAuth 2.0. 9 min · Beginner
- Configuration management tools, version control and Terraform for networksHow configuration management tools such as Ansible, Puppet, Chef and Salt differ (agent or agentless, push or pull, procedural or declarative), why Git version control matters for network changes, and how Terraform builds cloud and network infrastructure as code. 10 min · Intermediate
- SDN controllers in practice: OpenDaylight, ONOS and Cisco SD-AccessHow open-source SDN controllers OpenDaylight and ONOS are built and used, and how Cisco SD-Access turns the campus into a controller-driven fabric with Catalyst Center, a VXLAN overlay, a LISP control plane and group-based policy using SGTs and ISE. 10 min · Advanced
- Controller path trace and ACL analysis: from APIC-EM to Catalyst CenterWhat a controller-based path trace does, how the legacy Cisco APIC-EM path trace and ACL analysis tool worked, what replaced it in Catalyst Center Assurance, and how to check the same things by hand on the command line. 8 min · Intermediate
- AI and machine learning in networking: concepts, real uses and safe adoptionWhat artificial intelligence, machine learning and generative AI are, the main kinds of machine learning, and how they are used in network operations: baselining, anomaly detection, root-cause analysis, Wi-Fi optimisation and AI assistants, with their limits and risks. 9 min · Beginner
- Python for network engineers: strings, f-strings, input, split and slicingThe Python text skills network scripts use most: creating and changing strings, useful string methods, formatting reports with f-strings, asking the user for input, splitting device output into fields, and slicing out the part you need. 9 min · Beginner
- Python operators for network engineers: arithmetic, comparison, logic, membership and bitwiseThe Python operators network scripts rely on, with network examples: arithmetic for bandwidth and capacity, comparison and logical operators for decisions, membership and identity tests, and bitwise operators that show how subnet masks really work. 9 min · Beginner
- Streaming telemetry with gNMI: subscribing to YANG data instead of polling SNMPWhat model-driven streaming telemetry is and why it is replacing SNMP polling: gNMI and gRPC, YANG paths, sample and on-change subscriptions, dial-in and dial-out, collectors such as Telegraf and gnmic, storing data in a time-series database, and a simple subscription example. 7 min · Intermediate
- Parsing network CLI output with TextFSM, Genie and TTPHow to turn show command output into structured data for automation: the problem with string matching, TextFSM templates and the NTC templates collection, using them with Netmiko, Cisco Genie parsers, TTP templates, choosing between them and when to use APIs instead. 7 min · Intermediate
- Network testing with pyATS and Genie: snapshots, diffs and automated checksHow to use Cisco pyATS and Genie to test networks: testbed files, connecting to devices, learning features such as OSPF and BGP into structured data, comparing before and after snapshots for changes, writing simple test scripts, and using them in change windows and pipelines. 7 min · Advanced
- Using the NetBox API with pynetbox: reading and updating your source of truth from PythonHands-on use of the NetBox REST API with the pynetbox library: creating an API token, querying devices, interfaces, IP addresses and VLANs, filtering, creating and updating objects, allocating the next available IP or prefix, and using the data to generate configuration. 7 min · Intermediate
- GitOps for network teams: managing configuration changes through Git and pull requestsHow network teams can adopt GitOps: storing intended configuration and variables in Git, branching and pull requests for changes, automated checks in pipelines, approvals, deployment after merge, drift detection, rollback by reverting commits, and a gradual path for teams new to Git. 7 min · Intermediate
- Building network labs as code with ContainerlabHow to use Containerlab to build reproducible network labs for learning and testing automation: installing it, writing a topology file with Nokia SR Linux or Arista cEOS nodes and Linux hosts, deploying, connecting, adding startup configuration, using labs in CI pipelines and resource tips. 7 min · Intermediate
- Scrapli for network automation: fast SSH and NETCONF connections in PythonAn introduction to the Scrapli Python library: connecting to Cisco, Juniper and Arista devices over SSH, sending commands and configuration, structured output with TextFSM or Genie, asyncio support for many devices, scrapli-netconf, and how it compares with Netmiko. 6 min · Intermediate
- Concurrency in network automation: threads, asyncio and safe limitsHow to run automation tasks against many devices at once: why network scripts are I/O bound, using ThreadPoolExecutor with Netmiko, asyncio basics, Nornir's built-in concurrency, choosing worker limits, handling errors per device, and protecting AAA servers and devices from overload. 7 min · Intermediate
- Handling credentials in network automation: secrets managers, service accounts and least privilegeHow to keep passwords, API tokens and keys safe in network automation: why credentials must not live in scripts or Git, using environment variables, encrypted files and secrets managers such as HashiCorp Vault, dedicated automation accounts with least privilege in TACACS+, rotation, and scanning repositories for leaked secrets. 6 min · Intermediate
- Safe automated network changes: dry runs, canaries, batches and rollbackPatterns that stop automation from spreading mistakes across the whole network: idempotent tasks, dry runs and check mode, configuration diffs, canary devices, batch rollouts, automatic stop conditions, commit confirmed and rollback, protecting management access, and clear logging. 7 min · Intermediate
- Event-driven network automation: responding to alerts with rulebooks and webhooksHow event-driven automation reacts to network events: event sources such as syslog, telemetry alerts and webhooks, Event-Driven Ansible rulebooks, typical use cases from gathering diagnostics to safe remediation, guard rails, and how to start with low-risk actions. 7 min · Advanced
- Automating FortiGate firewalls with the FortiOS REST API and PythonHow to use the FortiOS REST API: creating a REST API administrator with a token and trusted hosts, the difference between cmdb and monitor endpoints, reading system status, listing and creating address objects with Python requests, error handling, VDOMs, and security precautions. 7 min · Intermediate
- Testing your automation code with pytest: templates, data validation and functionsHow network engineers can test their own automation code with pytest: writing simple test functions, testing Jinja2 templates render the right configuration, validating variables such as VLAN IDs and IP addresses, using fixtures and parametrisation, and running tests in a pipeline. 6 min · Intermediate
- Using AI coding assistants for network automation safelyHow network engineers can use AI assistants to write and understand automation code: good uses such as drafting scripts, templates and regex, explaining unfamiliar code, writing tests and documentation; the risks of invented commands, insecure code and leaked data; and a safe workflow with review and lab testing. 6 min · Beginner
- Project: discovering your network topology with LLDP and PythonA hands-on project that discovers network devices and links by crawling LLDP or CDP neighbours from a seed switch with Netmiko and TextFSM, avoiding loops, recording links, handling unreachable devices, and exporting results to CSV for documentation or a source of truth. 8 min · Intermediate