kowabunga.cloud.netplan role – Install and configures host network through Netplan.

Note

This role is part of the kowabunga.cloud collection (version 0.1.0).

It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it use: ansible-galaxy collection install kowabunga.cloud.

To use it in a playbook, specify: kowabunga.cloud.netplan.

Entry point main – Install and configures host network through Netplan.

Synopsis

  • Install and configures host network through Netplan.

Parameters

Parameter

Comments

kowabunga_netplan_apply_enabled

boolean

Defines whether Netplan’s generated configuration should be applied.

Disabled if unspecified.

Choices:

  • false ← (default)

  • true

kowabunga_netplan_config

dictionary

Network configuration settings for Netplan.

No change unless specified.

Default: {}

bond

list / elements=dictionary

Defines IEEE 802.3ad LACP (Link Aggregation Control Protocol) (i.e. interface bonding/teaming) network interface configuration settings, if any.

Default: []

dhcp

boolean

Defines whether interface should be configured manually (default) or through DCHP.

Choices:

  • false ← (default)

  • true

dns

list / elements=string

List of DNS servers to be used.

Default: ["9.9.9.9", "149.112.112.112"]

interfaces

list / elements=string / required

List of network interface names to be bonded together.

ips

list / elements=string

List of IP addresses to be associated to the configured interface.

Formated as CIDR (e.g. 10.0.0.1/24).

None if empty (i.e. unconfigured).

Default: []

lacp_rate

string

Set the rate at which LACPDUs are transmitted.

This is only useful in 802.3ad mode.

Choices:

  • "fast" ← (default)

  • "slow"

mac

string / required

Bonding interface physical MAC address.

Example: aa:bb:cc:dd:ee:ff

metric

integer

Defines interface’s gateway route metric priority.

Routes with lower values are preferred.

Default: 100

mii_interval

integer

Specifies the interval for MII monitoring (verifying if an interface of the bond has carrier).

A value of 0 disables MII monitoring.

The value is interpreted as milliseconds.

Default: 100

mode

string

Bonding mode for the interface.

Choices:

  • "balance-rr"

  • "active-backup"

  • "balance-xor"

  • "broadcast"

  • "802.3ad" ← (default)

  • "balance-tlb"

  • "balance-alb"

mtu

integer

Set Maximum Transmission Unit (MTU) for the interface.

Useful to enable Jumbo frames (MTU 9000) for example.

Default: 1500

name

string / required

Linux bonding interface name.

Example: bond0

policy

string

Specifies the transmit hash policy for the selection of ports.

This is only useful in ‘balance-xor’, ‘802.3ad’ and ‘balance-tlb’ modes.

Choices:

  • "layer2"

  • "layer3+4"

  • "layer2+3" ← (default)

  • "encap2+3"

  • "encap3+4"

routes

list / elements=dictionary

List of routes to be configured through the specified network interface.

Default: []

metric

integer

Defines interface’s gateway route metric priority.

Routes with lower values are preferred.

Default: 100

to

string / required

Destination network to be reached.

Formated as CIDR (e.g. 10.0.0.0/8)

Accepts “default” for native route.

via

string / required

Network gateway IP address.

list / elements=string

List of search domains to be used.

Default: []

bridge

list / elements=dictionary

Defines IEEE 802.1d network interface bridging settings, if any.

Default: []

delay

integer

Specify the period of time the bridge will remain in Listening and Learning states before getting to the Forwarding state.

The value is interpreted as seconds.

Default: 4

dhcp

boolean

Defines whether interface should be configured manually (default) or through DCHP.

Choices:

  • false ← (default)

  • true

dns

list / elements=string

List of DNS servers to be used.

Default: ["9.9.9.9", "149.112.112.112"]

interfaces

list / elements=string / required

List of network interface names o be part of the bridged interface..

ips

list / elements=string

List of IP addresses to be associated to the configured interface.

Formated as CIDR (e.g. 10.0.0.1/24).

None if empty (i.e. unconfigured).

Default: []

metric

integer

Defines interface’s gateway route metric priority.

Routes with lower values are preferred.

Default: 100

mtu

integer

Set Maximum Transmission Unit (MTU) for the interface.

Useful to enable Jumbo frames (MTU 9000) for example.

Default: 1500

name

string / required

Linux bridged interface name.

Example: br0

routes

list / elements=dictionary

List of routes to be configured through the specified network interface.

Default: []

metric

integer

Defines interface’s gateway route metric priority.

Routes with lower values are preferred.

Default: 100

to

string / required

Destination network to be reached.

Formated as CIDR (e.g. 10.0.0.0/8)

Accepts “default” for native route.

via

string / required

Network gateway IP address.

list / elements=string

List of search domains to be used.

Default: []

stp

boolean

Define whether the bridge should use Spanning Tree Protocol.

Enabled if unspecified.

Choices:

  • false

  • true ← (default)

ethernet

list / elements=dictionary

Defines low-level ethernet network interfaces configuration settings.

Default: []

dhcp

boolean

Defines whether interface should be configured manually (default) or through DCHP.

Choices:

  • false ← (default)

  • true

dns

list / elements=string

List of DNS servers to be used.

Default: ["9.9.9.9", "149.112.112.112"]

ips

list / elements=string

List of IP addresses to be associated to the configured interface.

Formated as CIDR (e.g. 10.0.0.1/24).

None if empty (i.e. unconfigured).

Default: []

mac

string / required

Interface physical MAC address.

Example: aa:bb:cc:dd:ee:ff

metric

integer

Defines interface’s gateway route metric priority.

Routes with lower values are preferred.

Default: 100

mtu

integer

Set Maximum Transmission Unit (MTU) for the interface.

Useful to enable Jumbo frames (MTU 9000) for example.

Default: 1500

name

string / required

Linux interface name.

Example: eth0, eno1 …

routes

list / elements=dictionary

List of routes to be configured through the specified network interface.

Default: []

metric

integer

Defines interface’s gateway route metric priority.

Routes with lower values are preferred.

Default: 100

to

string / required

Destination network to be reached.

Formated as CIDR (e.g. 10.0.0.0/8)

Accepts “default” for native route.

via

string / required

Network gateway IP address.

list / elements=string

List of search domains to be used.

Default: []

vlan

list / elements=dictionary

Defines IEEE 802.1q (i.e. VLAN) network interface configuration settings, if any.

Default: []

dhcp

boolean

Defines whether interface should be configured manually (default) or through DCHP.

Choices:

  • false ← (default)

  • true

dns

list / elements=string

List of DNS servers to be used.

Default: ["9.9.9.9", "149.112.112.112"]

id

integer / required

Associated VLAN ID.

Ranges from 0 to 4094.

ips

list / elements=string

List of IP addresses to be associated to the configured interface.

Formated as CIDR (e.g. 10.0.0.1/24).

None if empty (i.e. unconfigured).

Default: []

string / required

Name fo the underlying network interface to add VLAN on top of.

Example: eth0

metric

integer

Defines interface’s gateway route metric priority.

Routes with lower values are preferred.

Default: 100

mtu

integer

Set Maximum Transmission Unit (MTU) for the interface.

Useful to enable Jumbo frames (MTU 9000) for example.

Default: 1500

name

string / required

Linux VLAN interface name.

Example: vlan100

routes

list / elements=dictionary

List of routes to be configured through the specified network interface.

Default: []

metric

integer

Defines interface’s gateway route metric priority.

Routes with lower values are preferred.

Default: 100

to

string / required

Destination network to be reached.

Formated as CIDR (e.g. 10.0.0.0/8)

Accepts “default” for native route.

via

string / required

Network gateway IP address.

list / elements=string

List of search domains to be used.

Default: []

kowabunga_netplan_disable_cloud_init

boolean

Defines whether Netplan’s cloud-init generated configuration should remain.

Kept if unspecified.

Choices:

  • false ← (default)

  • true