summaryrefslogtreecommitdiff
path: root/cloudinit/distros
diff options
context:
space:
mode:
authorJoshua Harlow <harlowja@gmail.com>2016-05-19 14:26:30 -0700
committerJoshua Harlow <harlowja@gmail.com>2016-05-19 14:26:30 -0700
commit6b97c4e462b19374d6af807b1f5b9c087aa97996 (patch)
tree3628a55f69b61644a519d5df40398d55ba55186c /cloudinit/distros
parentea4bc2c603a9d964a918e01d00e39a851e979830 (diff)
parent880d9fc2f9c62abf19b1506595aa81e5417dea45 (diff)
downloadvyos-cloud-init-6b97c4e462b19374d6af807b1f5b9c087aa97996.tar.gz
vyos-cloud-init-6b97c4e462b19374d6af807b1f5b9c087aa97996.zip
Remerge against head/master
Diffstat (limited to 'cloudinit/distros')
-rw-r--r--cloudinit/distros/debian.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/cloudinit/distros/debian.py b/cloudinit/distros/debian.py
index 32bef1cd..e71aaa97 100644
--- a/cloudinit/distros/debian.py
+++ b/cloudinit/distros/debian.py
@@ -26,6 +26,7 @@ from cloudinit import distros
from cloudinit import helpers
from cloudinit import log as logging
from cloudinit import net
+from cloudinit.net import eni
from cloudinit import util
from cloudinit.distros.parsers.hostname import HostnameConf
@@ -56,6 +57,7 @@ class Distro(distros.Distro):
# should only happen say once per instance...)
self._runner = helpers.Runners(paths)
self.osfamily = 'debian'
+ self._net_renderer = eni.Renderer()
def apply_locale(self, locale, out_fn=None):
if not out_fn:
@@ -80,10 +82,10 @@ class Distro(distros.Distro):
def _write_network_config(self, netconfig):
ns = net.parse_net_config_data(netconfig)
- net.render_network_state(target="/", network_state=ns,
- eni=self.network_conf_fn,
- links_prefix=self.links_prefix,
- netrules=None)
+ self._net_renderer.render_network_state(
+ target="/", network_state=ns,
+ eni=self.network_conf_fn, links_prefix=self.links_prefix,
+ netrules=None)
_maybe_remove_legacy_eth0()
return []