Networks operated from Kubernetes and Crossplane, from one tunnel to a whole fabric's design. Lab twins to try each change on first.
-
-
Latest
-
-
-
Site-to-Site VPN from Cisco IOS XE to AWS, managed from Kubernetes
-
One Kubernetes object makes the VPN connection on AWS and both tunnels on a Cisco IOS XE router, keeps them by reconcile, and shows both sides in its status.
-
-
AWS's recommended settings, from its sample configuration
-
keys rotated one tunnel at a time, the other carrying traffic
An NMS decides what you can automate, and when. This method lets you decide: one problem at a time, starting from the configuration already on your devices, with what you learn kept in packages you own and release.
What makes the network work is what you know. The setting the YANG does not model. The write the router refuses while another is in progress. The new key that does nothing until the SA is cleared. All of it lives only in your head, a wiki or a post-incident note, and you are the one who has to remember it, every time.
-
-
-
function-avd
-
Runs AVD in Kubernetes: builds each switch's configuration from those objects, pushes it over eAPI, and pushes it again after a change by hand.
The answer on offer to both is an NMS: the vendor automates what it chose to support, encodes what network engineers know, and sells it back to you, late.
+
+
+
+
Why
+
Computing solved this years ago
+
+
+
How computing does it
+
Write down what should be there, let a control loop keep it there, and change it through Git. Servers, cloud and applications have run this way for more than a decade. What a human operator knows went into software that does the work.
-
-
-
-
Run a lab
-
-
-
netclab-chart
-
Helm chart that runs routers, hosts and traffic generators as pods (cEOS, SR Linux, FRR, ixia-c), cabled together with Multus. You describe a topology; it becomes a running network. netclab, on PyPI, brings the cluster and the lab up in one command.
A router is not a container. You cannot throw it away and start a fresh one. It holds a configuration somebody wrote by hand, and its vendor decides how it can be reached.
-
-
-
-
Configure devices
-
-
-
netclab-xp
-
Crossplane packages that turn router configuration into Kubernetes resources: configuration-eos for Arista EOS, from a single interface up to a whole router, over RESTCONF, JSON-RPC or eAPI, configuration-iosxe for Cisco IOS XE over RESTCONF, and configuration-aws-vpn for a Site-to-Site VPN between AWS and IOS XE.
The method: the same loop, for devices as they are
+
Each section of a device's configuration becomes an object. Two loops meet on it.
+
+
+
+
+
+
+
You change the spec through Git, as a pull request. Review, history and rollback come with it.
+
Crossplane reads the router into the status on every poll and writes back what differs. A change made by hand is put back.
+
The status says whether it works, not only what was sent: the tunnel's interface, its SA, the BGP session. A next step can wait on it.
+
Try every change on a twin first: the same objects against a lab of the same devices, on your laptop.
+
+
+
The same on one real object, a tunnel interface on Cisco IOS XE, shortened:
+
kind: TunnelInterface
+metadata:
+ name: r1--tunnel0--d311cfe5
+spec:# what should be there: yours, through Git
+ managementPolicy: Replace
+ deviceRef: {name: r1}
+ name: Tunnel0
+ mode: ipsec-ipv4
+ ipv4Address: 192.168.100.1/24
+ source: GigabitEthernet2
+ destination: 10.0.23.2
+ ipsecProfile: CLASSICAL-IPSEC
+status:# read from the router on every poll
+ observed:# the section as the router holds it
+ destination: 10.0.23.2
+ ipsecProfile: CLASSICAL-IPSEC
+ ipv4Address: 192.168.100.1/24
+ mode: ipsec-ipv4
+ source: GigabitEthernet2
+ drift: [] # nothing differs from the spec
+ oper:# whether it works
+ interface: ready
+ peers:
+ - address: 10.0.23.2
+ ikeSA: active
+ reverted:# a description added by hand, taken off
+ extra:
+ - field: description
+ device: ['"by hand"']
+
+
Observe before writing
+
A router configured by hand is taken over one section at a time. Nothing is written until you move a section up.
+
+
+
+
+
+
+
How
+
Kubernetes, in network terms
+
You do not need to run a Kubernetes platform to start. Most of it maps onto things you already know:
+
+
+
On the network
In Kubernetes
+
+
the intended configuration
an object's spec
+
show commands
the object's status
+
a routing protocol, converging
reconcile: the loop that keeps converging on the spec
+
the CLI
kubectl
+
a configuration template you add
a new kind of object, defined in YAML with Crossplane
+
+
+
+
Kubernetes runs on your laptop in Docker, with kind (Kubernetes in Docker). For convenience, one command does the setup:
+
uvx netclab up
+
It runs the steps you could run by hand: a kind cluster, then Crossplane and a lab when asked. What it leaves is a plain cluster, and kubectl works with it as usual. Images such as cEOS you bring yourself, as for any lab.
+
+
+
+
How
+
Your knowledge is the asset
+
What you learn about a device goes into a package you own, tested against the device and released. It stops being something in your head and becomes something your team versions, reviews and builds on. Nobody waits for a vendor's roadmap, and the next engineer installs a version instead of finding it out again.
+
+
+
What an engineer found out
What the package does about it
+
+
IOS XE 17.18 has no post-quantum preshared key in its YANG
writes it over the CLI by RPC; on 26.x, where the YANG has it, over RESTCONF, picked by the router's version
A new kind of object is two pieces of YAML, with no controller code:
+
+
+
+
If you have written Jinja templates for Ansible, the composition will look familiar.
+
+
Floor by floor
+
A kind can compose other kinds. Each floor is a package of its own, with its own releases, and speaks its own words: the router's at the bottom, the service's above.
+
+
+
+
The device floor is worth having on its own: configuration-iosxe keeps a router's IPsec sections with nothing above it. Build up when a service needs it. Then the VPN team works with the few fields of a Connection, and what the IOS XE expert encoded in the floor below is used without being repeated.
+
Where a good model already exists, adopt it instead of building one. An AVD repository keeps Arista AVD's own design model, the knowledge its community encoded, and the cluster runs it as it is.
+
+
Start with the exercises
+
It started with Arista EOS: configuration-eos holds the first exercises, settings over eAPI and RESTCONF, rough in places. It is being rewritten as a tutorial, a step a page: a device, then a BGP neighbor between two cEOS nodes, with the session's state in the status.
which problem to solve first, and how far to take it
+
how fast: each section observed before anything is written
+
how a device is reached: RESTCONF, eAPI, or its CLI where the YANG stops
+
when: there is no roadmap to wait for
+
whether to build a model, build on one, or adopt one that exists
+
where your packages live: a public registry, or a private one
+
whether to leave: plain Kubernetes and Crossplane, open source under Apache-2.0
+
+
+
+
+
Everything here
+
+
+
netclab and netclab-chart
+
One command brings up Kubernetes on your laptop with a lab: routers, hosts and traffic generators as pods (cEOS, SR Linux, FRR, ixia-c), cabled with Multus.