MAAS is sending a "global" nameserver, and a ethernet device on a bridge. cloud-init is rendering that nameserver onto the ethernet device rather than on the bridge or as a "global" entry.
$ cat my.yaml network: config: [ {"id": "enp0s25", "type": "physical", "name": "enp0s25", "mac_address": "b8:ae:ed:7d:16:d0", "mtu": 1500, "subnets": [{"type": "manual"}]}, {"id": "br0", "type": "bridge", "name": "br0", "mac_address": "b8:ae:ed:7d:16:d0", "bridge_interfaces": ["enp0s25"], "mtu": 1500, "params": {'bridge_fd': 15, 'bridge_stp': 0}, "subnets": [ {"type": "static", "address": "10.90.90.4/24", "dns_nameservers": [], "gateway": "10.90.90.1"} ]}, {"type": "nameserver", "address": ["10.90.90.1"], "search": ["maaslab", "maas"]}, ] version: 1
$ PYTHONPATH=$PWD python3 ./tools/net-convert.py \ --network-data=my.yaml --kind=yaml --output-kind=netplan --directory=out.d
$ cat out.d/etc/netplan/50-cloud-init.yaml
network: version: 2 ethernets: enp0s25: match: macaddress: b8:ae:ed:7d:16:d0 mtu: 1500 nameservers: addresses: - 10.90.90.1 search: - maaslab - maas set-name: enp0s25 bridges: br0: addresses: - 10.90.90.4/24 gateway4: 10.90.90.1 interfaces: - enp0s25 parameters: forward-delay: 15 stp: false
MAAS is sending a "global" nameserver, and a ethernet device on a bridge.
cloud-init is rendering that nameserver onto the ethernet device rather
than on the bridge or as a "global" entry.
$ cat my.yaml ed:7d:16: d0", "mtu": 1500, ed:7d:16: d0", "bridge_ interfaces" : ["enp0s25"],
network:
config: [
{"id": "enp0s25", "type": "physical", "name": "enp0s25",
"mac_address": "b8:ae:
"subnets": [{"type": "manual"}]},
{"id": "br0", "type": "bridge", "name": "br0",
"mac_address": "b8:ae:
"mtu": 1500, "params": {'bridge_fd': 15, 'bridge_stp': 0},
"subnets": [
{"type": "static", "address": "10.90.90.4/24", "dns_nameservers": [],
"gateway": "10.90.90.1"}
]},
{"type": "nameserver", "address": ["10.90.90.1"],
"search": ["maaslab", "maas"]},
]
version: 1
$ PYTHONPATH=$PWD python3 ./tools/ net-convert. py \ data=my. yaml --kind=yaml --output- kind=netplan --directory=out.d
--network-
$ cat out.d/etc/ netplan/ 50-cloud- init.yaml
network:
macaddress: b8:ae:ed:7d:16:d0
nameserver s:
addresses:
search:
set- name: enp0s25
addresses:
gateway4: 10.90.90.1
interfaces :
parameters :
forward- delay: 15
stp: false
version: 2
ethernets:
enp0s25:
match:
mtu: 1500
- 10.90.90.1
- maaslab
- maas
bridges:
br0:
- 10.90.90.4/24
- enp0s25