summaryrefslogtreecommitdiffstats
path: root/roles/lib_yaml_editor/build/ansible/yedit.py
diff options
context:
space:
mode:
authorKenny Woodson <kwoodson@redhat.com>2016-03-31 16:29:20 -0400
committerKenny Woodson <kwoodson@redhat.com>2016-04-04 12:27:37 -0400
commitfcf8e6f1af68797e4a54efb22a47095fc4e3bedf (patch)
tree4339ee6a75490cf5cba20a278545d9932a2b0bab /roles/lib_yaml_editor/build/ansible/yedit.py
parent9451e288a77ed09cad19ef4fe27479f5b808277f (diff)
downloadopenshift-fcf8e6f1af68797e4a54efb22a47095fc4e3bedf.tar.gz
openshift-fcf8e6f1af68797e4a54efb22a47095fc4e3bedf.tar.bz2
openshift-fcf8e6f1af68797e4a54efb22a47095fc4e3bedf.tar.xz
openshift-fcf8e6f1af68797e4a54efb22a47095fc4e3bedf.zip
Yedit enhancements
Diffstat (limited to 'roles/lib_yaml_editor/build/ansible/yedit.py')
-rw-r--r--roles/lib_yaml_editor/build/ansible/yedit.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/roles/lib_yaml_editor/build/ansible/yedit.py b/roles/lib_yaml_editor/build/ansible/yedit.py
index bf868fb71..a4c0d40b3 100644
--- a/roles/lib_yaml_editor/build/ansible/yedit.py
+++ b/roles/lib_yaml_editor/build/ansible/yedit.py
@@ -24,7 +24,7 @@ def main():
yamlfile = Yedit(module.params['src'], module.params['content'])
- rval = yamlfile.get()
+ rval = yamlfile.load()
if not rval and state != 'present':
module.fail_json(msg='Error opening file [%s]. Verify that the' + \
' file exists, that it is has correct permissions, and is valid yaml.')
@@ -51,7 +51,7 @@ def main():
rval = yamlfile.create(module.params['key'], value)
else:
yamlfile.write()
- rval = yamlfile.get()
+ rval = yamlfile.load()
module.exit_json(changed=rval[0], results=rval[1], state="present")
module.exit_json(failed=True,