Merge lp:~smoser/cloud-init/trunk.1590104 into lp:~cloud-init-dev/cloud-init/trunk

Proposed by Scott Moser
Status: Merged
Merged at revision: 1228
Proposed branch: lp:~smoser/cloud-init/trunk.1590104
Merge into: lp:~cloud-init-dev/cloud-init/trunk
Diff against target: 12 lines (+1/-1)
1 file modified
cloudinit/stages.py (+1/-1)
To merge this branch: bzr merge lp:~smoser/cloud-init/trunk.1590104
Reviewer Review Type Date Requested Status
cloud-init Commiters Pending
Review via email: mp+296711@code.launchpad.net

Commit message

make networking config provided in system config override datasource.

while datasource provided networking is more dynamic in most cases,
preference should still be given to networking configuration provided
in the system.

This is because the user of the image should be ultimately in control
of the networking configuration if they so choose.

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'cloudinit/stages.py'
2--- cloudinit/stages.py 2016-06-01 21:17:11 +0000
3+++ cloudinit/stages.py 2016-06-07 18:37:57 +0000
4@@ -618,7 +618,7 @@
5 dscfg = ('ds', self.datasource.network_config)
6 sys_cfg = ('system_cfg', self.cfg.get('network'))
7
8- for loc, ncfg in (cmdline_cfg, dscfg, sys_cfg):
9+ for loc, ncfg in (cmdline_cfg, sys_cfg, dscfg):
10 if net.is_disabled_cfg(ncfg):
11 LOG.debug("network config disabled by %s", loc)
12 return (None, loc)