PRG PATH · TECHNOLOGY

Network Programmability

From the CLI to the programmable network. You start with Python, the language of network automation, then move on to Ansible and infrastructure as code with Terraform.

ACTIVEPython · Ansible · Terraform

Topics in this path

Three topics in order: first the language, then configuration automation and, finally, infrastructure as code. Topic 1 is already free to access.

TOPIC 01SDN and automationFundamentals of SDN, network automation and programmability: from the data model and FCAPS to DevOps and Intent-Based Networking.

COURSE

Fundamentals of Network Programmability

11 chapters covering the fundamentals of network programmability: why automate, the barriers, FCAPS, the business case, the common framework, DevOps, the reasons for programmability, APIs, data modeling, telemetry and Intent-Based Networking.

  • COURSE SHEET
  • AuthorJesús Espinoza
  • Chapters11
  • LevelIntermediate
  • LanguagesES · EN · FR · PT
TOPIC 02PythonThe complete Python for Everyone course, from zero to modules, testing and distribution, updated to Python 3.14.

COURSE

Python for Everyone

21 chapters that take you from your first program to sockets, threads, databases, testing and packaging. Every example was written with network engineers in mind, and all the code was tested with Python 3.14.6.

The course is based on the book Python para todos by Raúl González Duque (Creative Commons Attribution 2.5 Spain license), originally written for Python 2.5. Jesús Espinoza, with AI assistance, brought it to Python 3.14: he rewrote it with networking examples, updated the syntax and the modules that no longer exist and fixed errors in the original, chapter by chapter, against the official documentation.

Official Python 3.14 documentation ↗

  • COURSE FACTS
  • Original bookPython para todos
  • AuthorRaúl González Duque
  • Python versionPython 3.14
  • Chapters21
  • Original licenseCC BY 2.5 ES

CHAPTERS

  1. 1What is Python?Origins, bytecode, dynamic and strong typing, implementations, installing Python 3.14, venv, the REPL, IPython and editors · 11 min readRead the chapter
  2. 2My first Python programprint(), .py scripts, input(), running on Windows, the shebang and chmod · 6 min readRead the chapter
  3. 3Basic typesint, float, complex, arithmetic and bitwise operators, strings, raw strings, bytes, f-strings, booleans and comparisons · 10 min readRead the chapter
  4. 4CollectionsLists, negative indexes, slicing, tuples, strings as sequences, dictionaries, views and nested JSON · 7 min readRead the chapter
  5. 5Control flowif, elif and else, ternary operator, match and case, while, for, range, break and continue · 9 min readRead the chapter
  6. 6Functionsdef and docstrings, positional and keyword arguments, default values, *args and **kwargs, / and *, argument passing, return, type annotations · 8 min readRead the chapter
  7. 7Object orientationClasses and objects, inheritance and super(), multiple inheritance and MRO, polymorphism, encapsulation, @property, special methods, rich comparisons, dataclasses · 12 min readRead the chapter
  8. 8Revisiting objectsDictionary methods (get, pop, items, views, the | operator, setdefault), string methods (find, count, partition, replace, split, join, removeprefix) and list methods (append, extend, pop, remove, sort with key) · 7 min readRead the chapter
  9. 9Functional programmingHigher-order functions, map, filter and reduce, lambda, list, dictionary and set comprehensions, generators and yield, decorators, functools.wraps · 8 min readRead the chapter
  10. 10ExceptionsTracebacks, try/except/else/finally, several types and except without parentheses (PEP 758), raise and raise from, custom exceptions, add_note, ExceptionGroup and except*, hierarchy · 7 min readRead the chapter
  11. 11Modules and packagesimport, from and as, sys.path and PYTHONPATH, __name__ == "__main__", __doc__, packages and __init__.py, relative imports, namespace packages, pip and venv · 8 min readRead the chapter
  12. 12Input/output and filesinput(), sys.argv and argparse, print(), formatting with %, format and f-strings, open() and with, modes, reading, writing, seek/tell, pathlib · 10 min readRead the chapter
  13. 13Regular expressionsRaw strings, metacharacters, classes, quantifiers, anchors, match/search/fullmatch, named groups, findall, sub, split, compile and flags · 10 min readRead the chapter
  14. 14SocketsSocket families and types, bytes and encode/decode, TCP server and client, echo, create_server, timeouts, UDP with a syslog receiver, socketserver · 8 min readRead the chapter
  15. 15Interacting with the weburllib.request, urlopen, HTTPError and URLError, GET and POST with urlencode, headers with Request, openers and handlers, RESTCONF-style JSON REST API, cookies, requests and httpx · 10 min readRead the chapter
  16. 16ThreadsProcesses and threads, the GIL and free-threading, threading.Thread, Lock, RLock, Semaphore, Condition, Event, threading.local, queue.Queue, ThreadPoolExecutor · 13 min readRead the chapter
  17. 17Object serializationSerialization, marshal, pickle, protocols, pickle security, shelve, json · 8 min readRead the chapter
  18. 18DatabasesDB API 2.0 (PEP 249), sqlite3, connection and cursor, commit and rollback, fetch, parameterized queries, SQL injection, types, ORMs · 11 min readRead the chapter
  19. 19DocumentationDocstrings, PEP 257, help() and pydoc, reStructuredText, Sphinx, Google and NumPy styles, type annotations · 9 min readRead the chapter
  20. 20TestingUnit tests, doctest, unittest, assert methods, setUp and tearDown, python -m unittest, pytest · 8 min readRead the chapter
  21. 21Distributing applicationspyproject.toml, venv, pip, build, sdist and wheel, console scripts, twine and TestPyPI, zipapp, PyInstaller · 10 min readRead the chapter
TOPIC 03AnsibleNetwork configuration automation with playbooks, inventories and vendor collections.COMING SOON

COMING SOON

Ansible

Ansible automates tasks across hundreds of devices without installing agents: it connects over SSH or an API and applies what you describe in a playbook. It's the natural next step after Python.

We're preparing this topic. In the meantime, finish Python: it's the foundation for everything that follows.

Ansible documentation ↗

  • ANSIBLE
  • ToolAnsible (Red Hat)
  • FormatYAML playbooks
  • ConnectionSSH and API, agentless
  • For networksCollections such as cisco.ios
TOPIC 04TerraformInfrastructure as code: describe networks and cloud services in HCL and deploy them with plan and apply.COMING SOON

COMING SOON

Terraform

Terraform describes infrastructure as code: you write the desired state and the tool works out and applies the changes. It's the common language for deploying networks on AWS, Azure and Google Cloud.

We're preparing this topic. In the meantime, finish Python: it's the foundation for everything that follows.

Terraform documentation ↗

  • TERRAFORM
  • ToolTerraform (HashiCorp)
  • LanguageHCL
  • ModelDeclarative: plan and apply
  • CertificationTerraform Associate (004)
Back to learning paths