Default dns search list

This seems so basic, but I can’t find it in the UI or via googling…

I want to add two additional domains to the DNS search list. The are resolve-able via the upstream server. Do I have to do this in a curtin script? Any examples?

MAAS 2.8 installed via snap deploying ubuntu 20.04

Hi @jeremy-mordkoff, do you want to just change the configuration of a single machine or of a subnet?

For a subnet, you can configure the DNS in the UI as per this screenshot:

Hi @sparkiegeek – The entire subnet. I see the option to reconfigure the nameserver itself but not a place to set the search list.

Ah sorry, misunderstood what you were after.

So essentially you want a search line in resolv.conf, you should use cloud-init - maybe will help? covers how to specify cloud-init configuration to your deployments

actually that not work as network config overwrite this setting for ex netplan config

cat /etc/netplan/50-cloud-init.yaml

This file is generated from information provided by the datasource. Changes

to it will not persist across an instance reboot. To disable cloud-init’s

network configuration capabilities, write a file

/etc/cloud/cloud.cfg.d/99-disable-network-config.cfg with the following:

network: {config: disabled}

macaddress: 00:16:3e:00:ce:00
mtu: 1500
- maas
set-name: enp5s0
version: 2

any other workaround?

You might write a custom cloud-init script to parse and update the 50-cloud-init.yaml and then run netplan apply like in this similar use case Custom cloud-init network configuration examples please? - #8 by r00ta