Cani alpha add interface
cani alpha add interface
Add an interface to a device.
Synopsis
Add a standalone interface (e.g. a LAG) to an existing device.
Use this to create interfaces that are not part of a device-type template, such as LAG interfaces used to aggregate physical members.
After creating a LAG, assign members with:
cani update interface --device
Examples: cani alpha add interface lag256 --device switch-01 --type lag cani alpha add interface lag256 --device switch-01 --type lag --mode tagged --tagged-vlan 100,200 cani alpha add interface lag256 --device switch-01 --type lag --mode access --untagged-vlan 10
cani alpha add interface [flags]
Options
--device string Device name or UUID (required)
--type string Interface type (e.g. lag, virtual, 1000base-t) (default "lag")
--role string Interface role
--label string Interface label
--mac string MAC address (e.g. aa:bb:cc:dd:ee:ff)
--mode string 802.1Q mode: access, tagged, or tagged-all
--untagged-vlan int Untagged (native) VLAN ID
--tagged-vlan stringSlice Tagged VLAN IDs (comma-separated or repeatable)
--vrf string VRF name
Options inherited from parent commands
-a, --auto Automatically recommend values for parent hardware
-y, --accept Automatically accept recommended values.
-L, --list-supported-types List supported hardware types.
-q, --qty int Quantity of items to add. (default 1)
-p, --parent string Parent item UUID. (default "00000000-0000-0000-0000-000000000000")
--prefix string Name prefix for sequential naming (used with --qty).
--start int Starting number for sequential names (used with --prefix). (default 1)
--pad-width int Zero-pad width for sequential names (0 = auto).
--tag stringArray Tag(s) to apply to the item (repeatable)
--metadata stringArray Provider metadata key=value pairs (repeatable)
--status string Status (Active, Available, Connected, Decommissioned, Decommissioning, Deprecated, Deprovisioning, Down, End-of-Life, Extended Support, Failed, Inventory, Maintenance, Offline, Planned, Primary, Provisioning, Reserved, Retired, Secondary, Staging, or any custom status)
--serial string Serial number
--config string config file (default "/home/runner/.cani/cani.yml")
--debug enable debug mode
--datastore string datastore type (json, postgres) (default "json")
--datastore-path string override path to the datastore file (for testing)
--types-dirs stringSlice local directories with additional hardware types
--types-repos stringSlice git repo URLs with additional hardware types
--types-repo-clone clone types repos that are not yet cached locally
--types-repo-pull pull latest changes from types repos on startup
--strict require a resolved device type (slug) for all devices (default true)
SEE ALSO
- cani alpha add - Add items to the inventory