commit 3d3cbed501fb6a62c0a3538fce58505bcd7181bc (HEAD -> fix/tests-command-output-simple-warn)
Author: Scott Moser <smoser@brickies.net>
Date: Fri Oct 20 15:10:42 2017 -0400
cc_lxd: do not warn if 'bridge' is not provided in config.
lxd/bridge is not required to be provided, but a warning was being
logged if it was not. Avoid the warning when it is not present.
diff --git a/cloudinit/config/cc_lxd.py b/cloudinit/config/cc_lxd.py
index e6262f8c..09374d2e 100644
--- a/cloudinit/config/cc_lxd.py
+++ b/cloudinit/config/cc_lxd.py
@@ -72,7 +72,7 @@ def handle(name, cfg, cloud, log, args):
type(init_cfg))
init_cfg = {}
- bridge_cfg = lxd_cfg.get('bridge')
+ bridge_cfg = lxd_cfg.get('bridge', {})
if not isinstance(bridge_cfg, dict):
log.warn("lxd/bridge config must be a dictionary. found a '%s'",
type(bridge_cfg))