This lab demonstrates the integration between Nokia EDA and NetBox for IPAM (IP Address Management) synchronization. It shows how EDA can dynamically create allocation pools based on NetBox's IPAM Prefixes and post allocated objects back to NetBox.
The NetBox app in EDA enables:
- Dynamic creation of allocation pools based on NetBox Prefixes
- Synchronization of allocated resources back to NetBox
- Automated tracking of resource ownership
- Working EDA installation
kubectl
access to the EDA clusteruv
tool (will be installed by init script)helm
v3.x installed - https://helm.sh/docs/intro/install/
- 2 Spine switches (spine1, spine2)
- 2 Leaf switches (leaf1, leaf2)
- 2 Linux servers (server1, server2)
- All devices are Nokia SR Linux based
- Webhook for real-time updates
- Event rules for IPAM synchronization
- Custom fields for EDA tracking
- Pre-configured tags and prefixes
-
Initialize the lab:
./init.sh
This will:
- Install NetBox using Helm ( takes ~10 minutes )
- Create Kubernetes secrets
- Configure webhook endpoint
- Set up initial prefixes and tags
-
Configure NetBox (optional - for manual setup):
uv run scripts/configure_netbox.py
-
Deploy Containerlab topology:
containerlab deploy -t eda-nb.clab.yaml
-
Import topology to EDA:
clab-connector integrate \ --topology-data clab-eda-nb/topology-data.json \ --eda-url "https://$(cat .eda_api_address)" \ --skip-edge-intfs
-
Apply EDA resources:
# Install NetBox app kubectl apply -f manifests/0001_netbox_app_install.yaml # Wait for the netbox app to be ready # Apply remaining resources kubectl apply -f manifests/
- URL: Check
.netbox_url
file or runkubectl get svc -n netbox
- Username:
admin
- Password:
netbox
- Stored in
.eda_api_address
file
Defines connection to NetBox:
apiVersion: netbox.eda.nokia.com/v1alpha1
kind: Instance
metadata:
name: netbox
namespace: eda
spec:
url: http://netbox-server.netbox.svc.cluster.local
apiToken: netbox-api-token
signatureKey: netbox-webhook-signature
Map NetBox prefixes to EDA allocation pools:
Type | EDA Pool | Use Case |
---|---|---|
ip-address |
IPAllocationPool | System IPs |
ip-in-subnet |
IPInSubnetAllocationPool | Management IPs |
subnet |
SubnetAllocationPool | ISL links |
-
Create Prefix in NetBox:
- Navigate to IPAM → Prefixes
- Add prefix (e.g.,
192.168.100.0/24
) - Set Status to
Active
(for IP pools) orContainer
(for subnet pools) - Add appropriate tag (e.g.,
eda-systemip-v4
)
-
EDA Creates Allocation Pool:
- NetBox sends webhook to EDA
- EDA creates matching allocation pool
- Pool name matches Allocation resource name
-
Use in Fabric:
apiVersion: fabrics.eda.nokia.com/v1alpha1 kind: Fabric metadata: name: netbox-ebgp-fabric spec: systemPoolIPV4: nb-systemip-v4 interSwitchLinks: poolIPV4: nb-isl-v4
-
View Allocations in NetBox:
- Allocated IPs appear under original prefix
- Custom fields show EDA owner and allocation
eda-systemip-v4
- IPv4 System IPseda-systemip-v6
- IPv6 System IPseda-isl-v4
- IPv4 ISL subnetseda-isl-v6
- IPv6 ISL subnetseda-mgmt-v4
- Management IPsEDAManaged
- Auto-assigned to EDA allocations
192.168.10.0/24
- System IPs (Active)10.0.0.0/16
- ISL subnets (Container)2001:db8::/32
- IPv6 System IPs (Active)2005::/64
- IPv6 ISL subnets (Container)172.16.0.0/16
- Management IPs (Active)
kubectl get instance netbox -n clab-eda-nb -o yaml
kubectl get allocation -n clab-eda-nb
kubectl logs -n eda-system -l app=netbox
kubectl port-forward -n netbox service/netbox-server 8001:80 --address=0.0.0.0
To remove all lab resources:
./cleanup.sh
containerlab destroy -t eda-nb.clab.yaml
- EDA NetBox App Detailed Guide - Comprehensive documentation on the NetBox app including configuration examples and troubleshooting
- NetBox Documentation
- Containerlab Documentation