summaryrefslogtreecommitdiff
path: root/cloudinit/distros
diff options
context:
space:
mode:
Diffstat (limited to 'cloudinit/distros')
-rw-r--r--cloudinit/distros/freebsd.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/cloudinit/distros/freebsd.py b/cloudinit/distros/freebsd.py
index aa468bca..754d3df6 100644
--- a/cloudinit/distros/freebsd.py
+++ b/cloudinit/distros/freebsd.py
@@ -132,6 +132,12 @@ class Distro(distros.Distro):
LOG.debug("Using network interface %s", bsddev)
return bsddev
+ def _select_hostname(self, hostname, fqdn):
+ # Should be FQDN if available. See rc.conf(5) in FreeBSD
+ if fqdn:
+ return fqdn
+ return hostname
+
def _read_system_hostname(self):
sys_hostname = self._read_hostname(filename=None)
return ('rc.conf', sys_hostname)