summaryrefslogtreecommitdiff
path: root/cloudinit/distros
diff options
context:
space:
mode:
authorScott Moser <smoser@ubuntu.com>2016-07-13 22:10:22 -0400
committerScott Moser <smoser@ubuntu.com>2016-07-13 22:10:22 -0400
commit7d58c949c2f5d7821ec664ed25167dfea92964f7 (patch)
tree2131aed5cd436c0562c86673a5854b5da10be79f /cloudinit/distros
parentefef1c263ab1c473fd90f3782a785edab7d02430 (diff)
downloadvyos-cloud-init-7d58c949c2f5d7821ec664ed25167dfea92964f7.tar.gz
vyos-cloud-init-7d58c949c2f5d7821ec664ed25167dfea92964f7.zip
pass the return back up, shorten lines some.
Diffstat (limited to 'cloudinit/distros')
-rw-r--r--cloudinit/distros/__init__.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/cloudinit/distros/__init__.py b/cloudinit/distros/__init__.py
index 006a7062..40af8802 100644
--- a/cloudinit/distros/__init__.py
+++ b/cloudinit/distros/__init__.py
@@ -141,17 +141,18 @@ class Distro(object):
return False
def _apply_network_from_network_config(self, netconfig, bring_up=True):
+ distro = self.__class__
LOG.warn("apply_network_config is not currently implemented "
- "for distribution '%s'. Attempting to use "
- "apply_network", self.__class__)
+ "for distribution '%s'. Attempting to use apply_network",
+ distro)
header = '\n'.join([
- "# Converted from network_config for distro %s" % self.__class__,
+ "# Converted from network_config for distro %s" % distro,
"# Implmentation of _write_network_config is needed."
])
ns = network_state.parse_net_config_data(netconfig)
contents = eni.network_state_to_eni(
ns, header=header, render_hwaddress=True)
- self.apply_network(contents, bring_up=bring_up)
+ return self.apply_network(contents, bring_up=bring_up)
def apply_network_config(self, netconfig, bring_up=False):
# apply network config netconfig