added stdout and stderr outputs (#1900)

* added stdout and stderr outputs

Added stdout and stderr outputs of the results from composer as the current msg output strips \n so very hard to read when debugging

* using stdout for fail_json

using stdout for fail_json so we get the stdout_lines array
pull/18777/head
Him You Ten 9 years ago committed by Matt Clay
parent d2d4001dc5
commit 87ce503767

@ -220,11 +220,11 @@ def main():
if rc != 0:
output = parse_out(err)
module.fail_json(msg=output)
module.fail_json(msg=output, stdout=err)
else:
# Composer version > 1.0.0-alpha9 now use stderr for standard notification messages
output = parse_out(out + err)
module.exit_json(changed=has_changed(output), msg=output)
module.exit_json(changed=has_changed(output), msg=output, stdout=out+err)
# import module snippets
from ansible.module_utils.basic import *

Loading…
Cancel
Save