Skip to content

Cani alpha update interface

cani alpha update interface

Update interface properties.

Synopsis

Update one or more interfaces on a device or module.

Examples: # List interfaces on a device cani update interface --device switch-01 -L

# Set role by device name and interface name cani update interface --device switch-01 --name osfp1 --role hsn

# Set role on multiple interfaces matching a glob pattern cani update interface --device switch-01 --name "1/1/*" --role UplinkInterface

# Set role by interface UUID cani update interface 3fa85f64-5717-4562-b3fc-2c963f66afa6 --role management

# Set label on an interface cani update interface --device server-01 --name eth0 --label "BMC Network"

# Set MAC address on an interface cani update interface --device server-01 --name iLO --mac aa:bb:cc:dd:ee:ff

# Target a specific module's interface (disambiguates names shared with the # parent device or sibling modules, e.g. multiple "HSN 0" ports on one node) cani update interface --module CX7-server-01 --name "HSN 0" --mac aa:bb:cc:dd:ee:ff

cani alpha update interface [flags]

Options

      --device string          Device name or UUID (required when not using positional UUID)
      --module string          Module name or UUID (targets only that module's own interfaces)
      --name string            Interface name or glob pattern (e.g. "1/1/*")
      --role string            Interface role (e.g. management, hsn, storage, access)
      --label string           Interface label
      --mac string             Interface MAC address (e.g. aa:bb:cc:dd:ee:ff)
  -L, --list                   List interfaces for the specified device

Options inherited from parent commands

      --set stringArray        Set field value as key=value (repeatable)
      --tag stringArray        Tag(s) to apply to the item (repeatable)
      --metadata stringArray   Provider metadata key=value pairs (repeatable)
      --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