diff options
author | Andrew Butcher <abutcher@afrolegs.com> | 2017-02-24 13:29:54 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-24 13:29:54 -0500 |
commit | bc0df10bdebc5dd1874c10ac701626e9ea6465de (patch) | |
tree | da637ae80df8c9db5bb1052632be108d52c87b27 | |
parent | c2528f6ecda7e8f6ef5ffdccecd3f3532f2af03f (diff) | |
parent | ddee19f5097ea1013016c956bfc0f255690c8cb9 (diff) | |
download | openshift-bc0df10bdebc5dd1874c10ac701626e9ea6465de.tar.gz openshift-bc0df10bdebc5dd1874c10ac701626e9ea6465de.tar.bz2 openshift-bc0df10bdebc5dd1874c10ac701626e9ea6465de.tar.xz openshift-bc0df10bdebc5dd1874c10ac701626e9ea6465de.zip |
Merge pull request #3486 from tbielawa/bz1421053
Fix Quick Installer failed due to a Python method failure
-rw-r--r-- | utils/src/ooinstall/ansible_plugins/facts_callback.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/utils/src/ooinstall/ansible_plugins/facts_callback.py b/utils/src/ooinstall/ansible_plugins/facts_callback.py index e51890a22..c881e4b92 100644 --- a/utils/src/ooinstall/ansible_plugins/facts_callback.py +++ b/utils/src/ooinstall/ansible_plugins/facts_callback.py @@ -5,6 +5,7 @@ import os import yaml from ansible.plugins.callback import CallbackBase +from ansible.parsing.yaml.dumper import AnsibleDumper # pylint: disable=super-init-not-called @@ -38,7 +39,11 @@ class CallbackModule(CallbackBase): facts = abridged_result['result']['ansible_facts']['openshift'] hosts_yaml = {} hosts_yaml[res._host.get_name()] = facts - os.write(self.hosts_yaml, yaml.safe_dump(hosts_yaml)) + to_dump = yaml.dump(hosts_yaml, + allow_unicode=True, + default_flow_style=False, + Dumper=AnsibleDumper) + os.write(self.hosts_yaml, to_dump) def v2_runner_on_skipped(self, res): pass |