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
reviewable/pr18780/r1
Him You Ten 9 years ago committed by René Moser
parent 0405c54dba
commit f99576749a

@ -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