summaryrefslogtreecommitdiff
path: root/cloudinit/handlers
diff options
context:
space:
mode:
authorJoshua Harlow <harlowja@gmail.com>2012-11-22 08:26:20 -0800
committerJoshua Harlow <harlowja@gmail.com>2012-11-22 08:26:20 -0800
commitcc765725c6493082e8e2f72f78de9786b6e2cc2a (patch)
tree4062a8ea2c416248441d52b1605f8d288b0a95b4 /cloudinit/handlers
parent0596e8db112a031095e8f5cbdae770e8f3ca4bbb (diff)
downloadvyos-cloud-init-cc765725c6493082e8e2f72f78de9786b6e2cc2a.tar.gz
vyos-cloud-init-cc765725c6493082e8e2f72f78de9786b6e2cc2a.zip
Continue work.
Diffstat (limited to 'cloudinit/handlers')
-rw-r--r--cloudinit/handlers/cloud_config.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/cloudinit/handlers/cloud_config.py b/cloudinit/handlers/cloud_config.py
index ba07b2ef..50fbb445 100644
--- a/cloudinit/handlers/cloud_config.py
+++ b/cloudinit/handlers/cloud_config.py
@@ -50,13 +50,14 @@ class CloudConfigPartHandler(handlers.Handler):
util.write_file(self.cloud_fn, "\n".join(lines), 0600)
def _merge_part(self, payload, headers, filename):
- merge_headers_how = headers.get("Merge-Type")
+ merge_headers = headers.get("Merge-Type")
try:
payload_y = util.load_yaml(payload)
merge_how = ''
- for merge_i in [payload_y.pop("Merge-Type", ''), merge_headers_how]:
+ for merge_i in [payload_y.pop("Merge-Type", ''), merge_headers]:
if merge_i:
merge_how = merge_i
+ break
merge_how = merge_how.strip().lower()
if not merge_how:
merge_how = DEF_MERGE_TYPE