diff options
author | Brent Baude <bbaude@redhat.com> | 2017-03-20 12:31:15 -0500 |
---|---|---|
committer | Scott Moser <smoser@brickies.net> | 2017-03-21 09:37:55 -0400 |
commit | 86715c88aab8561e1ddadac95671f6095d16f9e7 (patch) | |
tree | bd2820e0fa87bc14863421fd55dab95040758322 /cloudinit/sources/__init__.py | |
parent | ef18b8ac4cf7e3dfd98830fbdb298380a192a0fc (diff) | |
download | vyos-cloud-init-86715c88aab8561e1ddadac95671f6095d16f9e7.tar.gz vyos-cloud-init-86715c88aab8561e1ddadac95671f6095d16f9e7.zip |
Bounce network interface for Azure when using the built-in path.
When deploying on Azure and using only cloud-init, you must "bounce" the
network interface to trigger a DDNS update. This allows dhclient to
register the hostname with Azure so that DNS works correctly on their
private networks (i.e. between vm and vm).
The agent path was already doing the bounce so this creates parity
between the built-in path and the agent.
LP: #1674685
Diffstat (limited to 'cloudinit/sources/__init__.py')
-rw-r--r-- | cloudinit/sources/__init__.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cloudinit/sources/__init__.py b/cloudinit/sources/__init__.py index 3d01072f..18294505 100644 --- a/cloudinit/sources/__init__.py +++ b/cloudinit/sources/__init__.py @@ -210,7 +210,7 @@ class DataSource(object): else: hostname = toks[0] - if fqdn: + if fqdn and domain != defdomain: return "%s.%s" % (hostname, domain) else: return hostname |