cisco_iol

package
v0.83.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 6, 2026 License: BSD-3-Clause Imports: 21 Imported by: 0

Documentation

Index

Constants

View Source
const (
	NapalmPlatformName = "ios"
)

Variables

View Source
var (

	// IntfRegexp with named capture groups for extracting slot and port.
	CapturingIntfRegexp = regexp.MustCompile(`^(?:e|Ethernet)\s?(?P<slot>\d+)/(?P<port>\d+)$`)
	// ethX naming is the "raw" or "default" interface naming.
	DefaultIntfRegexp = regexp.MustCompile(`eth[1-9]\d*$`)
	// Matches on any allowed/legal interface name.
	AllowedIntfRegexp = regexp.MustCompile(`(e|Ethernet)((0/[0-3])|([1-9]/[0-3]))$|eth[1-9]\d*$`)
	IntfHelpMsg       = "" /* 196-byte string literal not displayed */

)

Functions

func Register

func Register(r *clabnodes.NodeRegistry)

Register registers the node in the NodeRegistry.

Types

type IOLInterface

type IOLInterface struct {
	IfaceName string
	IfaceIdx  int
	Slot      int
	Port      int
	IPv4Addr  string
	IPv4Mask  string
	IPv6Addr  string
}

IOLInterface struct stores mapping info between IOL interface name and linux container interface.

type IOLTemplateData

type IOLTemplateData struct {
	Hostname           string
	IsL2Node           bool
	MgmtIntf           string
	MgmtIPv4Addr       string
	MgmtIPv4SubnetMask string
	MgmtIPv4GW         string
	MgmtIPv6Addr       string
	MgmtIPv6PrefixLen  int
	MgmtIPv6GW         string
	DataIFaces         []IOLInterface
	PartialCfg         string
}

type KindSpecificConfig added in v0.80.0

type KindSpecificConfig struct {
	// PidOffset shifts the auto-assigned IOL PID, e.g. to keep IDs unique across labs.
	PidOffset *int `yaml:"pid-offset,omitempty" json:"pid-offset,omitempty"`
	// MgmtIntf is the management interface, e.g. Ethernet0/1. Defaults to Ethernet0/0.
	MgmtIntf string `yaml:"mgmt-intf,omitempty" json:"mgmt-intf,omitempty"`
	// BootstrapConfig replaces the default startup configuration with a file, or disables it
	// when set to "none".
	BootstrapConfig string `yaml:"bootstrap-config,omitempty" json:"bootstrap-config,omitempty"`
}

KindSpecificConfig is the cisco_iol kind-specific config, set as keys on the node definition.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL