Schema reference
This page covers the SP-demo-specific schema nodes defined in schemas/sp/.
Base and extension schemas (devices, interfaces, IPAM, routing) come from
the Infrahub schema-library and are not repeated here.
For the overall schema loading order and layering, see architecture.
ServiceL3Vpnโ
Namespace: Service ยท Kind: ServiceL3Vpn
File: schemas/sp/service_l3vpn.yml
Represents a single L3VPN service offered to a tenant. One ServiceL3Vpn
has one or more ServiceL3VpnSite attachments (component relationship).
Attributesโ
| Field | Kind | Required | Description | Who sets it |
|---|---|---|---|---|
name | Text | Required | Unique human name for the VPN (for example, acme-prod) | User |
description | Text | Optional | Free-text description | User |
vpn_id | Number | Required | Unique integer allocated from vpn_id_pool. Used to derive RD/RT as <asn>:<vpn_id> | User (catalog allocates from pool) |
address_family | Dropdown | Required | ipv4 or ipv4_ipv6. Defaults to ipv4 | User |
status | Dropdown | Required | draft โ active โ decommissioned. Defaults to draft | User sets draft; generator promotes to active |
Relationshipsโ
| Field | Peer | Cardinality | Required | Description | Who sets it |
|---|---|---|---|---|---|
tenant | OrganizationGeneric | one | Required | Owning organisation | User |
vrf | IpamVRF | one | Optional | VRF materialised by the generator | Generator |
sites | ServiceL3VpnSite | many | Optional | PE attachment points (component) | User / catalog |
ServiceL3VpnSiteโ
Namespace: Service ยท Kind: ServiceL3VpnSite
File: schemas/sp/service_l3vpn.yml
Represents a single PE attachment of an L3VPN to a customer subnet. One site = one PE + one customer-facing interface + a /30 PE-CE link.
Attributesโ
| Field | Kind | Required | Description | Who sets it |
|---|---|---|---|---|
name | Text | Required | Unique within a given l3vpn (uniqueness constraint) | User |
routing_protocol | Dropdown | Required | ebgp, static, or connected | User |
bgp_peer_asn | Number | Optional | Customer BGP ASN (required when routing_protocol = ebgp) | User |
static_routes | JSON | Optional | List of static routes to inject into the VRF | User |
status | Dropdown | Required | provisioning โ active โ decommissioned. Defaults to provisioning | Generator promotes to active |
Relationshipsโ
| Field | Peer | Cardinality | Required | Description | Who sets it |
|---|---|---|---|---|---|
l3vpn | ServiceL3Vpn | one | Required | Parent VPN (parent relationship) | User / catalog |
pe_device | DcimDevice | one | Required | PE router for this attachment | User |
pe_interface | InterfacePhysical | one | Optional | PE-facing physical interface | Generator allocates from free interfaces |
customer_subnet | IpamPrefix | one | Required | Customer prefix to be placed into the VRF | User |
pe_address | IpamIPAddress | one | Optional | PE IP on the PE-CE /30 link | Generator allocates from pe_ce_pool |
ce_address | IpamIPAddress | one | Optional | CE IP on the PE-CE /30 link | Generator allocates from pe_ce_pool |
ServiceSdwanโ
Namespace: Service ยท Kind: ServiceSdwan
File: schemas/sp/service_sdwan.yml
Represents a single SD-WAN service offered to a tenant. One ServiceSdwan
has one or more ServiceSdwanSite attachments (component relationship).
Attributesโ
| Field | Kind | Required | Description | Who sets it |
|---|---|---|---|---|
name | Text | Required | Unique human name for the SD-WAN service (for example, treasury-branch-sdwan) | User |
description | Text | Optional | Free-text description | User |
service_id | Number | Required | Unique integer allocated from sdwan_id_pool. Used for SD-WAN site-id derivation | User (catalog allocates from pool) |
vendor | Dropdown | Required | viptela (Cisco SD-WAN) or versa (Versa Networks). Defaults to viptela | User |
topology | Dropdown | Required | full-mesh or hub-spoke. Defaults to full-mesh | User |
status | Dropdown | Required | draft โ active โ decommissioned. Defaults to draft | User sets draft; generator promotes to active |
Relationshipsโ
| Field | Peer | Cardinality | Required | Description | Who sets it |
|---|---|---|---|---|---|
tenant | OrganizationGeneric | one | Required | Owning organisation | User |
sites | ServiceSdwanSite | many | Optional | SD-WAN edge sites (component) | User / catalog |
ServiceSdwanSiteโ
Namespace: Service ยท Kind: ServiceSdwanSite
File: schemas/sp/service_sdwan.yml
Represents a single SD-WAN edge site: one location, one edge device, one
LAN subnet, one LAN IP. The edge DcimDevice is created automatically by
the generator (it isn't pre-seeded in any dataset).
Attributesโ
| Field | Kind | Required | Description | Who sets it |
|---|---|---|---|---|
name | Text | Required | Unique within a given sdwan (uniqueness constraint) | User |
role | Dropdown | Required | hub, spoke, or branch. Defaults to spoke | User |
status | Dropdown | Required | provisioning โ active โ decommissioned. Defaults to provisioning | Generator promotes to active |
Relationshipsโ
| Field | Peer | Cardinality | Required | Description | Who sets it |
|---|---|---|---|---|---|
sdwan | ServiceSdwan | one | Required | Parent SD-WAN service (parent relationship) | User / catalog |
location | LocationSite | one | Required | Customer site / PoP this edge attaches to | User |
lan_subnet | IpamPrefix | one | Required | Customer LAN subnet behind this edge | User |
lan_address | IpamIPAddress | one | Optional | Edge's LAN IP (network address + 1) | Generator allocates from lan_subnet |
sdwan_edge | DcimDevice | one | Optional | Edge router materialised at this site | Generator creates per-site |
TopologyMplsBackboneโ
Namespace: Topology ยท Kind: TopologyMplsBackbone
File: schemas/sp/topology_mpls.yml
Inherits from TopologyGeneric. Represents the MPLS backbone as a whole โ
one row per backbone domain. The demo has exactly one row: mpls-backbone-1.
Attributesโ
| Field | Kind | Required | Description | Who sets it |
|---|---|---|---|---|
name | Text | Required | Unique backbone name | User (bootstrap) |
isis_area | Text | Required | ISIS area ID (default 49.0001) | User (bootstrap) |
isis_level | Dropdown | Required | level-1, level-2, or level-1-2 (default level-2) | User (bootstrap) |
Relationshipsโ
| Field | Peer | Cardinality | Required | Description | Who sets it |
|---|---|---|---|---|---|
asn | RoutingAutonomousSystem | one | Required | Provider ASN used for RD/RT derivation | User (bootstrap) |
pes | DcimDevice | many | Optional | All PE routers in this backbone | User (bootstrap) |
MplsIsisProcessโ
Namespace: Mpls ยท Kind: MplsIsisProcess
File: schemas/sp/mpls.yml
Inherits from RoutingProtocol. One row per PE representing the IS-IS
routing process. The device relationship is inherited from RoutingProtocol.
Attributesโ
| Field | Kind | Required | Description | Who sets it |
|---|---|---|---|---|
area_id | Text | Required | IS-IS area (default 49.0001) | User (bootstrap) |
level | Dropdown | Required | level-1, level-2, or level-1-2 (default level-2) | User (bootstrap) |
net_id | Text | Required | ISO NET identifier (for example, 49.0001.0100.0000.0001.00) | User (bootstrap) |
Relationshipsโ
| Field | Peer | Cardinality | Required | Description |
|---|---|---|---|---|
interfaces | InterfacePhysical | many | Optional | Backbone interfaces running IS-IS |
Inherited from RoutingProtocolโ
| Field | Description |
|---|---|
device | The PE device this process belongs to |
description | Free-text description |
status | active / inactive |
MplsLdpProcessโ
Namespace: Mpls ยท Kind: MplsLdpProcess
File: schemas/sp/mpls.yml
Inherits from RoutingProtocol. One row per PE representing the LDP
label distribution process.
Attributesโ
| Field | Kind | Required | Description | Who sets it |
|---|---|---|---|---|
router_id | Text | Required | LDP router-ID (typically the Loopback0 IP) | User (bootstrap) |
Relationshipsโ
| Field | Peer | Cardinality | Required | Description |
|---|---|---|---|---|
transport_address | IpamIPAddress | one | Optional | LDP transport address override |
interfaces | InterfacePhysical | many | Optional | Backbone interfaces running LDP |
MplsBgpProcessโ
Namespace: Mpls ยท Kind: MplsBgpProcess
File: schemas/sp/mpls.yml
Inherits from RoutingProtocol. One row per PE representing the MP-BGP
overlay process carrying VPNv4 / VPNv6 address families.
Attributesโ
| Field | Kind | Required | Description | Who sets it |
|---|---|---|---|---|
router_id | Text | Required | BGP router-ID (typically the Loopback0 IP) | User (bootstrap) |
address_families | List | Required | MP-BGP address families enabled (for example, ["vpnv4", "vpnv6"]) | User (bootstrap) |
Relationshipsโ
| Field | Peer | Cardinality | Required | Description |
|---|---|---|---|---|
sessions | RoutingBGPSession | many | Optional | iBGP sessions for this process |
LocationRegion / LocationSiteโ
Namespace: Location ยท File: schemas/sp/location_concrete.yml
Concrete location kinds for this demo. LocationRegion inherits from
LocationGeneric (the schema-library generic), and LocationSite adds
hosting capability via LocationHosting. Both render under
LocationGeneric in the sidebar menu. The bootstrap data uses
LocationRegion for emea and LocationSite for the four PoPs
(lon, fra, ams, par).
| Kind | Inherits | Purpose |
|---|---|---|
LocationRegion | LocationGeneric | Geographic region (for example, emea) |
LocationSite | LocationGeneric, LocationHosting | PoP / site that hosts PEs |
DcimDevice role extensionโ
File: schemas/sp/dcim_role_pe.yml
This file is a schema extension (not a new node) that adds SP-specific
choices to the existing DcimDevice.role dropdown:
| Role | Label | Use |
|---|---|---|
pe | Provider Edge | PE router terminating customer VPNs |
p | Provider Core | P router (transit only, no customer VRFs) |
rr | Route Reflector | BGP route reflector |
core | Core Router | Central part of the network |
edge | Edge Router | Network boundary with external networks |
cpe | Customer Premise Equipment | Devices at the customer's premises |
The demo bootstrap sets role = pe on all four PEs.
Resource poolsโ
The following pools are bootstrapped in objects/50_pools.yml and consumed
by the generator and the Streamlit catalog:
| Pool name | Kind | Purpose | Allocation unit |
|---|---|---|---|
vpn_id_pool | CoreNumberPool | Globally unique VPN IDs | Integer (range 200โ9999; values 100โ199 are reserved for bootstrap-seeded L3VPNs) |
sdwan_id_pool | CoreNumberPool | Globally unique SD-WAN service IDs | Integer (range 200โ9999; values 100โ199 are reserved for bootstrap-seeded SD-WANs) |
pe_loopback_pool | CoreIPPrefixPool | Loopback /32 addresses | /32 from 10.0.0.0/24 |
backbone_p2p_pool | CoreIPPrefixPool | Backbone p2p /31 links | /31 from 10.1.0.0/16 |
pe_ce_pool | CoreIPPrefixPool | PE-CE /30 links per L3VPN site | /30 from 10.100.0.0/16 |
User-provided vs generator-filled summaryโ
The following table consolidates which fields an operator must supply and which
the L3VpnGenerator fills in automatically:
| Object | Field | Source |
|---|---|---|
ServiceL3Vpn | name, vpn_id, address_family, tenant | User / catalog |
ServiceL3Vpn | vrf, status = active | Generator |
ServiceL3VpnSite | name, pe_device, routing_protocol, bgp_peer_asn, customer_subnet, l3vpn | User / catalog |
ServiceL3VpnSite | pe_interface, pe_address, ce_address, status = active | Generator |
IpamVRF | all | Generator |
IpamIPAddress (PE-CE) | all | Generator |
RoutingBGPSession (PE-CE) | all (only when routing_protocol = ebgp) | Generator |