Skip to main content
apiVersion: v1alpha1
kind: VLANConfig
name: enp0s3.34 # Name of the VLAN link (interface) to be created.
vlanID: 34 # VLAN ID to be used for the VLAN link.
parent: enp0s3 # Name of the parent link (interface) on which the VLAN link will be created.
# Configure addresses to be statically assigned to the link.
addresses:
    - address: 192.168.1.100/24 # IP address to be assigned to the link.
# Configure routes to be statically created via the link.
routes:
    - destination: 192.168.0.0/16 # The route's destination as an address prefix.
      gateway: 192.168.1.1 # The route's gateway (if empty, creates link scope route).

# # Set the VLAN mode to use.
# vlanMode: 802.1q
FieldTypeDescriptionValue(s)
namestringName of the VLAN link (interface) to be created.
vlanIDuint16VLAN ID to be used for the VLAN link.
vlanModeVLANProtocolSet the VLAN mode to use.
If not set, defaults to ‘802.1q’.
802.1q
802.1ad
parentstringName of the parent link (interface) on which the VLAN link will be created.
Link aliases can be used here as well.
upboolBring the link up or down.

If not specified, the link will be brought up.
mtuuint32Configure LinkMTU (Maximum Transmission Unit) for the link.

If not specified, the system default LinkMTU will be used (usually 1500).
addressesAddressConfigConfigure addresses to be statically assigned to the link.
routesRouteConfigConfigure routes to be statically created via the link.
multicastboolSet the multicast capability of the link.

addresses[]

AddressConfig represents a network address configuration.
FieldTypeDescriptionValue(s)
addressPrefixIP address to be assigned to the link.

This field must include the network prefix length (e.g. /24 for IPv4, /64 for IPv6).
routePriorityuint32Configure the route priority (metric) for routes created for this address.

If not specified, the system default route priority will be used.

routes[]

RouteConfig represents a network route configuration.
FieldTypeDescriptionValue(s)
destinationPrefixThe route’s destination as an address prefix.

If not specified, a default route will be created for the address family of the gateway.
gatewayAddrThe route’s gateway (if empty, creates link scope route).
sourceAddrThe route’s source address (optional).
metricuint32The optional metric for the route.
mtuuint32The optional MTU for the route.
tableRoutingTableThe routing table to use for the route.

If not specified, the main routing table will be used.