====== ContainerLAB ======
==== SETUP ====
On the Linux machine, download the Docker image and then import it. Some useful Docker commands:
docker import cEOS-lab-4.34.3.1M.tar.xz ceos:4.34.3.1M
docker images # should be visible here
docker ps # show all running containers
docker ps -a # show all containers, including stopped ones. Docker keeps its filesystem, metadata and
# reference to the image until you explicitly remove it
docker rm # removes the container
docker rmi # removes the image
Create a //topology.clab.yaml// file:
name: clos
prefix: ""
topology:
kinds:
ceos:
image: ceos:4.34.3.1M
env:
CLAB_MGMT_VRF: MGMT
nodes:
leaf1:
kind: ceos
leaf2:
kind: ceos
spine1:
kind: ceos
spine2:
kind: ceos
client1:
kind: linux
image: alpine:latest
client2:
kind: linux
image: alpine:latest
links:
# leaf to spine links POD1
- endpoints: ["leaf1:eth1", "spine1:eth1"]
- endpoints: ["leaf1:eth2", "spine2:eth1"]
- endpoints: ["leaf2:eth1", "spine1:eth2"]
- endpoints: ["leaf2:eth2", "spine2:eth2"]
# client connection links
- endpoints: ["client1:eth1", "leaf1:eth3"]
- endpoints: ["client2:eth1", "leaf2:eth3"]
Deploy the lab:
clab deploy