Blame doc/rtd/topics/network-config-format-v2.rst

Packit Service a04d08
.. _network_config_v2:
Packit Service a04d08
Packit Service a04d08
Networking Config Version 2
Packit Service a04d08
===========================
Packit Service a04d08
Packit Service a04d08
Cloud-init's support for Version 2 network config is a subset of the
Packit Service a04d08
version 2 format defined for the `netplan`_ tool.  Cloud-init supports
Packit Service a04d08
both reading and writing of Version 2; the latter support requires a
Packit Service a04d08
distro with `netplan`_ present.
Packit Service a04d08
Packit Service a04d08
The ``network`` key has at least two required elements.  First
Packit Service a04d08
it must include ``version: 2``  and one or more of possible device
Packit Service a04d08
``types``..
Packit Service a04d08
Packit Service a04d08
Cloud-init will read this format from system config.
Packit Service a04d08
For example the following could be present in
Packit Service a04d08
``/etc/cloud/cloud.cfg.d/custom-networking.cfg``::
Packit Service a04d08
Packit Service a04d08
  network:
Packit Service a04d08
    version: 2
Packit Service a04d08
    ethernets: []
Packit Service a04d08
Packit Service a04d08
It may also be provided in other locations including the
Packit Service a04d08
:ref:`datasource_nocloud`, see :ref:`default_behavior` for other places.
Packit Service a04d08
Packit Service a04d08
Supported device ``types`` values are as follows:
Packit Service a04d08
Packit Service a04d08
- Ethernets (``ethernets``)
Packit Service a04d08
- Bonds (``bonds``)
Packit Service a04d08
- Bridges (``bridges``)
Packit Service a04d08
- VLANs (``vlans``)
Packit Service a04d08
Packit Service a04d08
Each type block contains device definitions as a map where the keys (called
Packit Service a04d08
"configuration IDs"). Each entry under the ``types`` may include IP and/or
Packit Service a04d08
device configuration.
Packit Service a04d08
Packit Service a04d08
Cloud-init does not current support ``wifis`` type that is present in native
Packit Service a04d08
`netplan`_.
Packit Service a04d08
Packit Service a04d08
Packit Service a04d08
Device configuration IDs
Packit Service a04d08
------------------------
Packit Service a04d08
Packit Service a04d08
The key names below the per-device-type definition maps (like ``ethernets:``)
Packit Service a04d08
are called "ID"s. They must be unique throughout the entire set of
Packit Service a04d08
configuration files. Their primary purpose is to serve as anchor names for
Packit Service a04d08
composite devices, for example to enumerate the members of a bridge that is
Packit Service a04d08
currently being defined.
Packit Service a04d08
Packit Service a04d08
There are two physically/structurally different classes of device definitions,
Packit Service a04d08
and the ID field has a different interpretation for each:
Packit Service a04d08
Packit Service 11b429
Physical devices
Packit Service 11b429
Packit Service 11b429
:   (Examples: ethernet, wifi) These can dynamically come and go between
Packit Service a04d08
    reboots and even during runtime (hotplugging). In the generic case, they
Packit Service a04d08
    can be selected by ``match:`` rules on desired properties, such as
Packit Service a04d08
    name/name pattern, MAC address, driver, or device paths. In general these
Packit Service a04d08
    will match any number of devices (unless they refer to properties which are
Packit Service a04d08
    unique such as the full path or MAC address), so without further knowledge
Packit Service a04d08
    about the hardware these will always be considered as a group.
Packit Service a04d08
Packit Service a04d08
    It is valid to specify no match rules at all, in which case the ID field is
Packit Service a04d08
    simply the interface name to be matched. This is mostly useful if you want
Packit Service a04d08
    to keep simple cases simple, and it's how network device configuration has
Packit Service a04d08
    been done for a long time.
Packit Service a04d08
Packit Service a04d08
    If there are ``match``: rules, then the ID field is a purely opaque name
Packit Service a04d08
    which is only being used  for references from definitions of compound
Packit Service a04d08
    devices in the config.
Packit Service a04d08
Packit Service 11b429
Virtual devices
Packit Service 11b429
Packit Service 11b429
:  (Examples: veth, bridge, bond) These are fully under the control of the
Packit Service a04d08
   config file(s) and the network stack. I. e. these devices are being created
Packit Service a04d08
   instead of matched. Thus ``match:`` and ``set-name:`` are not applicable for
Packit Service a04d08
   these, and the ID field is the name of the created virtual device.
Packit Service a04d08
Packit Service a04d08
Common properties for physical device types
Packit Service a04d08
-------------------------------------------
Packit Service a04d08
Packit Service a04d08
**match**: *<(mapping)>*
Packit Service a04d08
Packit Service a04d08
This selects a subset of available physical devices by various hardware
Packit Service a04d08
properties. The following configuration will then apply to all matching
Packit Service a04d08
devices, as soon as they appear. *All* specified properties must match.
Packit Service a04d08
The following properties for creating matches are supported:
Packit Service a04d08
Packit Service a04d08
**name**:  *<(scalar)>*
Packit Service a04d08
Packit Service a04d08
Current interface name. Globs are supported, and the primary use case
Packit Service a04d08
for matching on names, as selecting one fixed name can be more easily
Packit Service a04d08
achieved with having no ``match:`` at all and just using the ID (see
Packit Service a04d08
above). Note that currently only networkd supports globbing,
Packit Service a04d08
NetworkManager does not.
Packit Service a04d08
Packit Service a04d08
**macaddress**: *<(scalar)>*
Packit Service a04d08
Packit Service a04d08
Device's MAC address in the form "XX:XX:XX:XX:XX:XX". Globs are not allowed.
Packit Service a04d08
Packit Service a04d08
**driver**: *<(scalar)>*
Packit Service a04d08
Packit Service a04d08
Kernel driver name, corresponding to the ``DRIVER`` udev property.  Globs are
Packit Service a04d08
supported. Matching on driver is *only* supported with networkd.
Packit Service a04d08
Packit Service a04d08
**Examples**::
Packit Service a04d08
Packit Service a04d08
  # all cards on second PCI bus
Packit Service a04d08
  match:
Packit Service a04d08
    name: enp2*
Packit Service a04d08
Packit Service a04d08
  # fixed MAC address
Packit Service a04d08
  match:
Packit Service a04d08
    macaddress: 11:22:33:AA:BB:FF
Packit Service a04d08
Packit Service a04d08
  # first card of driver ``ixgbe``
Packit Service a04d08
  match:
Packit Service a04d08
    driver: ixgbe
Packit Service a04d08
    name: en*s0
Packit Service a04d08
Packit Service a04d08
**set-name**: *<(scalar)>*
Packit Service a04d08
Packit Service a04d08
When matching on unique properties such as path or MAC, or with additional
Packit Service a04d08
assumptions such as "there will only ever be one wifi device",
Packit Service a04d08
match rules can be written so that they only match one device. Then this
Packit Service a04d08
property can be used to give that device a more specific/desirable/nicer
Packit Service a04d08
name than the default from udev’s ifnames.  Any additional device that
Packit Service a04d08
satisfies the match rules will then fail to get renamed and keep the
Packit Service a04d08
original kernel name (and dmesg will show an error).
Packit Service a04d08
Packit Service a04d08
**wakeonlan**: *<(bool)>*
Packit Service a04d08
Packit Service a04d08
Enable wake on LAN. Off by default.
Packit Service a04d08
Packit Service a04d08
Packit Service a04d08
Common properties for all device types
Packit Service a04d08
--------------------------------------
Packit Service a04d08
Packit Service a04d08
**renderer**: *<(scalar)>*
Packit Service a04d08
Packit Service a04d08
Use the given networking backend for this definition. Currently supported are
Packit Service a04d08
``networkd`` and ``NetworkManager``. This property can be specified globally
Packit Service a04d08
in ``networks:``, for a device type (in e. g. ``ethernets:``) or
Packit Service a04d08
for a particular device definition. Default is ``networkd``.
Packit Service a04d08
Packit Service a04d08
.. note::
Packit Service a04d08
Packit Service a04d08
  Cloud-init only supports networkd backend if rendering version2 config
Packit Service a04d08
  to the instance.
Packit Service a04d08
Packit Service a04d08
**dhcp4**: *<(bool)>*
Packit Service a04d08
Packit Service a04d08
Enable DHCP for IPv4. Off by default.
Packit Service a04d08
Packit Service a04d08
**dhcp6**: *<(bool)>*
Packit Service a04d08
Packit Service a04d08
Enable DHCP for IPv6. Off by default.
Packit Service a04d08
Packit Service a04d08
**addresses**: *<(sequence of scalars)>*
Packit Service a04d08
Packit Service a04d08
Add static addresses to the interface in addition to the ones received
Packit Service a04d08
through DHCP or RA. Each sequence entry is in CIDR notation, i. e. of the
Packit Service a04d08
form ``addr/prefixlen`` . ``addr`` is an IPv4 or IPv6 address as recognized
Packit Service a04d08
by ``inet_pton``(3) and ``prefixlen`` the number of bits of the subnet.
Packit Service a04d08
Packit Service a04d08
Example: ``addresses: [192.168.14.2/24, 2001:1::1/64]``
Packit Service a04d08
Packit Service a04d08
**gateway4**: or **gateway6**: *<(scalar)>*
Packit Service a04d08
Packit Service a04d08
Set default gateway for IPv4/6, for manual address configuration. This
Packit Service a04d08
requires setting ``addresses`` too. Gateway IPs must be in a form
Packit Service a04d08
recognized by ``inet_pton(3)``
Packit Service a04d08
Packit Service a04d08
Example for IPv4: ``gateway4: 172.16.0.1``
Packit Service a04d08
Example for IPv6: ``gateway6: 2001:4::1``
Packit Service a04d08
Packit Service a04d08
**mtu**: *<MTU SizeBytes>*
Packit Service a04d08
Packit Service a04d08
The MTU key represents a device's Maximum Transmission Unit, the largest size
Packit Service a04d08
packet or frame, specified in octets (eight-bit bytes), that can be sent in a
Packit Service a04d08
packet- or frame-based network.  Specifying ``mtu`` is optional.
Packit Service a04d08
Packit Service a04d08
**nameservers**: *<(mapping)>*
Packit Service a04d08
Packit Service a04d08
Set DNS servers and search domains, for manual address configuration. There
Packit Service a04d08
are two supported fields: ``addresses:`` is a list of IPv4 or IPv6 addresses
Packit Service a04d08
similar to ``gateway*``, and ``search:`` is a list of search domains.
Packit Service a04d08
Packit Service a04d08
Example: ::
Packit Service a04d08
Packit Service a04d08
  nameservers:
Packit Service a04d08
    search: [lab, home]
Packit Service a04d08
    addresses: [8.8.8.8, FEDC::1]
Packit Service a04d08
Packit Service a04d08
**routes**: *<(sequence of mapping)>*
Packit Service a04d08
Packit Service a04d08
Add device specific routes.  Each mapping includes a ``to``, ``via`` key
Packit Service a04d08
with an IPv4 or IPv6 address as value.  ``metric`` is an optional value.
Packit Service a04d08
Packit Service a04d08
Example: ::
Packit Service a04d08
Packit Service a04d08
  routes:
Packit Service a04d08
   - to: 0.0.0.0/0
Packit Service a04d08
     via: 10.23.2.1
Packit Service a04d08
     metric: 3
Packit Service a04d08
Packit Service a04d08
Ethernets
Packit Service a04d08
~~~~~~~~~
Packit Service a04d08
Ethernet device definitions do not support any specific properties beyond the
Packit Service a04d08
common ones described above.
Packit Service a04d08
Packit Service a04d08
Bonds
Packit Service a04d08
~~~~~
Packit Service a04d08
Packit Service a04d08
**interfaces** *<(sequence of scalars)>*
Packit Service a04d08
Packit Service a04d08
All devices matching this ID list will be added to the bond.
Packit Service a04d08
Packit Service a04d08
Example: ::
Packit Service a04d08
Packit Service a04d08
  ethernets:
Packit Service a04d08
    switchports:
Packit Service a04d08
      match: {name: "enp2*"}
Packit Service a04d08
  [...]
Packit Service a04d08
  bonds:
Packit Service a04d08
    bond0:
Packit Service a04d08
      interfaces: [switchports]
Packit Service a04d08
Packit Service a04d08
**parameters**: *<(mapping)>*
Packit Service a04d08
Packit Service a04d08
Customization parameters for special bonding options.  Time values are
Packit Service a04d08
specified in seconds unless otherwise specified.
Packit Service a04d08
Packit Service a04d08
**mode**: *<(scalar)>*
Packit Service a04d08
Packit Service a04d08
Set the bonding mode used for the interfaces. The default is
Packit Service a04d08
``balance-rr`` (round robin). Possible values are ``balance-rr``,
Packit Service a04d08
``active-backup``, ``balance-xor``, ``broadcast``, ``802.3ad``,
Packit Service a04d08
``balance-tlb``, and ``balance-alb``.
Packit Service a04d08
Packit Service a04d08
**lacp-rate**: *<(scalar)>*
Packit Service a04d08
Packit Service a04d08
Set the rate at which LACPDUs are transmitted. This is only useful
Packit Service a04d08
in 802.3ad mode. Possible values are ``slow`` (30 seconds, default),
Packit Service a04d08
and ``fast`` (every second).
Packit Service a04d08
Packit Service a04d08
**mii-monitor-interval**: *<(scalar)>*
Packit Service a04d08
Packit Service a04d08
Specifies the interval for MII monitoring (verifying if an interface
Packit Service a04d08
of the bond has carrier). The default is ``0``; which disables MII
Packit Service a04d08
monitoring.
Packit Service a04d08
Packit Service a04d08
**min-links**: *<(scalar)>*
Packit Service a04d08
Packit Service a04d08
The minimum number of links up in a bond to consider the bond
Packit Service a04d08
interface to be up.
Packit Service a04d08
Packit Service a04d08
**transmit-hash-policy**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Specifies the transmit hash policy for the selection of slaves. This
Packit Service a04d08
is only useful in balance-xor, 802.3ad and balance-tlb modes.
Packit Service a04d08
Possible values are ``layer2``, ``layer3+4``, ``layer2+3``,
Packit Service a04d08
``encap2+3``, and ``encap3+4``.
Packit Service a04d08
Packit Service a04d08
**ad-select**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Set the aggregation selection mode. Possible values are ``stable``,
Packit Service a04d08
``bandwidth``, and ``count``. This option is only used in 802.3ad mode.
Packit Service a04d08
Packit Service a04d08
**all-slaves-active**: <*(bool)>*
Packit Service a04d08
Packit Service a04d08
If the bond should drop duplicate frames received on inactive ports,
Packit Service a04d08
set this option to ``false``. If they should be delivered, set this
Packit Service a04d08
option to ``true``. The default value is false, and is the desirable
Packit Service a04d08
behavior in most situations.
Packit Service a04d08
Packit Service a04d08
**arp-interval**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Set the interval value for how frequently ARP link monitoring should
Packit Service a04d08
happen. The default value is ``0``, which disables ARP monitoring.
Packit Service a04d08
Packit Service a04d08
**arp-ip-targets**: <*(sequence of scalars)>*
Packit Service a04d08
Packit Service a04d08
IPs of other hosts on the link which should be sent ARP requests in
Packit Service a04d08
order to validate that a slave is up. This option is only used when
Packit Service a04d08
``arp-interval`` is set to a value other than ``0``. At least one IP
Packit Service a04d08
address must be given for ARP link monitoring to function. Only IPv4
Packit Service a04d08
addresses are supported. You can specify up to 16 IP addresses. The
Packit Service a04d08
default value is an empty list.
Packit Service a04d08
Packit Service a04d08
**arp-validate**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Configure how ARP replies are to be validated when using ARP link
Packit Service a04d08
monitoring. Possible values are ``none``, ``active``, ``backup``,
Packit Service a04d08
and ``all``.
Packit Service a04d08
Packit Service a04d08
**arp-all-targets**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Specify whether to use any ARP IP target being up as sufficient for
Packit Service a04d08
a slave to be considered up; or if all the targets must be up. This
Packit Service a04d08
is only used for ``active-backup`` mode when ``arp-validate`` is
Packit Service a04d08
enabled. Possible values are ``any`` and ``all``.
Packit Service a04d08
Packit Service a04d08
**up-delay**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Specify the delay before enabling a link once the link is physically
Packit Service a04d08
up. The default value is ``0``.
Packit Service a04d08
Packit Service a04d08
**down-delay**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Specify the delay before disabling a link once the link has been
Packit Service a04d08
lost. The default value is ``0``.
Packit Service a04d08
Packit Service a04d08
**fail-over-mac-policy**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Set whether to set all slaves to the same MAC address when adding
Packit Service a04d08
them to the bond, or how else the system should handle MAC addresses.
Packit Service a04d08
The possible values are ``none``, ``active``, and ``follow``.
Packit Service a04d08
Packit Service a04d08
**gratuitious-arp**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Specify how many ARP packets to send after failover. Once a link is
Packit Service a04d08
up on a new slave, a notification is sent and possibly repeated if
Packit Service a04d08
this value is set to a number greater than ``1``. The default value
Packit Service a04d08
is ``1`` and valid values are between ``1`` and ``255``. This only
Packit Service a04d08
affects ``active-backup`` mode.
Packit Service a04d08
Packit Service a04d08
**packets-per-slave**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
In ``balance-rr`` mode, specifies the number of packets to transmit
Packit Service a04d08
on a slave before switching to the next. When this value is set to
Packit Service a04d08
``0``, slaves are chosen at random. Allowable values are between
Packit Service a04d08
``0`` and ``65535``. The default value is ``1``. This setting is
Packit Service a04d08
only used in ``balance-rr`` mode.
Packit Service a04d08
Packit Service a04d08
**primary-reselect-policy**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Set the reselection policy for the primary slave. On failure of the
Packit Service a04d08
active slave, the system will use this policy to decide how the new
Packit Service a04d08
active slave will be chosen and how recovery will be handled. The
Packit Service a04d08
possible values are ``always``, ``better``, and ``failure``.
Packit Service a04d08
Packit Service a04d08
**learn-packet-interval**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Specify the interval between sending learning packets to each slave.
Packit Service a04d08
The value range is between ``1`` and ``0x7fffffff``. The default
Packit Service a04d08
value is ``1``. This option only affects ``balance-tlb`` and
Packit Service a04d08
``balance-alb`` modes.
Packit Service a04d08
Packit Service a04d08
Packit Service a04d08
Bridges
Packit Service a04d08
~~~~~~~
Packit Service a04d08
Packit Service a04d08
**interfaces**: <*(sequence of scalars)>*
Packit Service a04d08
Packit Service a04d08
All devices matching this ID list will be added to the bridge.
Packit Service a04d08
Packit Service a04d08
Example: ::
Packit Service a04d08
Packit Service a04d08
  ethernets:
Packit Service a04d08
    switchports:
Packit Service a04d08
      match: {name: "enp2*"}
Packit Service a04d08
  [...]
Packit Service a04d08
  bridges:
Packit Service a04d08
    br0:
Packit Service a04d08
      interfaces: [switchports]
Packit Service a04d08
Packit Service a04d08
**parameters**: <*(mapping)>*
Packit Service a04d08
Packit Service a04d08
Customization parameters for special bridging options.  Time values are
Packit Service a04d08
specified in seconds unless otherwise specified.
Packit Service a04d08
Packit Service a04d08
**ageing-time**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Set the period of time to keep a MAC address in the forwarding
Packit Service a04d08
database after a packet is received.
Packit Service a04d08
Packit Service a04d08
**priority**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Set the priority value for the bridge. This value should be an
Packit Service a04d08
number between ``0`` and ``65535``. Lower values mean higher
Packit Service a04d08
priority. The bridge with the higher priority will be elected as
Packit Service a04d08
the root bridge.
Packit Service a04d08
Packit Service a04d08
**forward-delay**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Specify the period of time the bridge will remain in Listening and
Packit Service a04d08
Learning states before getting to the Forwarding state. This value
Packit Service a04d08
should be set in seconds for the systemd backend, and in milliseconds
Packit Service a04d08
for the NetworkManager backend.
Packit Service a04d08
Packit Service a04d08
**hello-time**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Specify the interval between two hello packets being sent out from
Packit Service a04d08
the root and designated bridges. Hello packets communicate
Packit Service a04d08
information about the network topology.
Packit Service a04d08
Packit Service a04d08
**max-age**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Set the maximum age of a hello packet. If the last hello packet is
Packit Service a04d08
older than that value, the bridge will attempt to become the root
Packit Service a04d08
bridge.
Packit Service a04d08
Packit Service a04d08
**path-cost**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
Set the cost of a path on the bridge. Faster interfaces should have
Packit Service a04d08
a lower cost. This allows a finer control on the network topology
Packit Service a04d08
so that the fastest paths are available whenever possible.
Packit Service a04d08
Packit Service a04d08
**stp**: <*(bool)>*
Packit Service a04d08
Packit Service a04d08
Define whether the bridge should use Spanning Tree Protocol. The
Packit Service a04d08
default value is "true", which means that Spanning Tree should be
Packit Service a04d08
used.
Packit Service a04d08
Packit Service a04d08
Packit Service a04d08
VLANs
Packit Service a04d08
~~~~~
Packit Service a04d08
Packit Service a04d08
**id**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
VLAN ID, a number between 0 and 4094.
Packit Service a04d08
Packit Service a04d08
**link**: <*(scalar)>*
Packit Service a04d08
Packit Service a04d08
ID of the underlying device definition on which this VLAN gets
Packit Service a04d08
created.
Packit Service a04d08
Packit Service a04d08
Example: ::
Packit Service a04d08
Packit Service a04d08
  ethernets:
Packit Service a04d08
    eno1: {...}
Packit Service a04d08
  vlans:
Packit Service a04d08
    en-intra:
Packit Service a04d08
      id: 1
Packit Service a04d08
      link: eno1
Packit Service a04d08
      dhcp4: yes
Packit Service a04d08
    en-vpn:
Packit Service a04d08
      id: 2
Packit Service a04d08
      link: eno1
Packit Service a04d08
      address: ...
Packit Service a04d08
Packit Service a04d08
Packit Service a04d08
Examples
Packit Service a04d08
--------
Packit Service a04d08
Configure an ethernet device with networkd, identified by its name, and enable
Packit Service a04d08
DHCP: ::
Packit Service a04d08
Packit Service a04d08
  network:
Packit Service a04d08
    version: 2
Packit Service a04d08
    ethernets:
Packit Service a04d08
      eno1:
Packit Service a04d08
        dhcp4: true
Packit Service a04d08
Packit Service a04d08
This is a complex example which shows most available features: ::
Packit Service a04d08
Packit Service a04d08
  network:
Packit Service a04d08
    version: 2
Packit Service a04d08
    ethernets:
Packit Service a04d08
      # opaque ID for physical interfaces, only referred to by other stanzas
Packit Service a04d08
      id0:
Packit Service a04d08
        match:
Packit Service a04d08
          macaddress: 00:11:22:33:44:55
Packit Service a04d08
        wakeonlan: true
Packit Service a04d08
        dhcp4: true
Packit Service a04d08
        addresses:
Packit Service a04d08
          - 192.168.14.2/24
Packit Service a04d08
          - 2001:1::1/64
Packit Service a04d08
        gateway4: 192.168.14.1
Packit Service a04d08
        gateway6: 2001:1::2
Packit Service a04d08
        nameservers:
Packit Service a04d08
          search: [foo.local, bar.local]
Packit Service a04d08
          addresses: [8.8.8.8]
Packit Service a04d08
      lom:
Packit Service a04d08
        match:
Packit Service a04d08
          driver: ixgbe
Packit Service a04d08
        # you are responsible for setting tight enough match rules
Packit Service a04d08
        # that only match one device if you use set-name
Packit Service a04d08
        set-name: lom1
Packit Service a04d08
        dhcp6: true
Packit Service a04d08
      switchports:
Packit Service a04d08
        # all cards on second PCI bus; unconfigured by themselves, will be added
Packit Service a04d08
        # to br0 below
Packit Service a04d08
        match:
Packit Service a04d08
          name: enp2*
Packit Service a04d08
        mtu: 1280
Packit Service a04d08
    bonds:
Packit Service a04d08
      bond0:
Packit Service a04d08
        interfaces: [id0, lom]
Packit Service a04d08
    bridges:
Packit Service a04d08
      # the key name is the name for virtual (created) interfaces; no match: and
Packit Service a04d08
      # set-name: allowed
Packit Service a04d08
      br0:
Packit Service a04d08
        # IDs of the components; switchports expands into multiple interfaces
Packit Service a04d08
        interfaces: [wlp1s0, switchports]
Packit Service a04d08
        dhcp4: true
Packit Service a04d08
    vlans:
Packit Service a04d08
      en-intra:
Packit Service a04d08
        id: 1
Packit Service a04d08
        link: id0
Packit Service a04d08
        dhcp4: yes
Packit Service a04d08
    # static routes
Packit Service a04d08
    routes:
Packit Service a04d08
     - to: 0.0.0.0/0
Packit Service a04d08
       via: 11.0.0.1
Packit Service a04d08
       metric: 3
Packit Service a04d08
Packit Service a04d08
.. _netplan: https://launchpad.net/netplan
Packit Service a04d08
.. vi: textwidth=78