)]}'
{"doc/source/admin/components.rst":[{"author":{"_account_id":16068,"name":"Tobias Henkel","email":"tobias.henkel@bmw.de","username":"tobias.henkel"},"change_message_id":"c7ba08fb9e7d4f67ce3da39594e6688d666457c6","unresolved":false,"context_lines":[{"line_number":543,"context_line":"      :default: /tmp/console-{log_uuid}.log"},{"line_number":544,"context_line":""},{"line_number":545,"context_line":"      The filename template used to store Ansible command output,"},{"line_number":546,"context_line":"      formated with the log_uuid parameter."},{"line_number":547,"context_line":""},{"line_number":548,"context_line":"   .. attr:: log_stream_port"},{"line_number":549,"context_line":"      :default: 19885"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f93b717_dd7cd020","line":546,"range":{"start_line":546,"start_character":6,"end_line":546,"end_character":14},"updated":"2018-01-30 21:05:29.000000000","message":"formatted","commit_id":"32907a663ea3e6d430997fc3dcbb2dea2842b32c"},{"author":{"_account_id":9311,"name":"Tristan Cacqueray","email":"tdecacqu@redhat.com","username":"tristanC"},"change_message_id":"c439072e624ab0a72bf512b387e2a43a3837ce69","unresolved":false,"context_lines":[{"line_number":543,"context_line":"      :default: /tmp/console-{log_uuid}.log"},{"line_number":544,"context_line":""},{"line_number":545,"context_line":"      The filename template used to store Ansible command output,"},{"line_number":546,"context_line":"      formated with the log_uuid parameter."},{"line_number":547,"context_line":""},{"line_number":548,"context_line":"   .. attr:: log_stream_port"},{"line_number":549,"context_line":"      :default: 19885"}],"source_content_type":"text/x-rst","patch_set":1,"id":"9fdfeff1_8467b34d","line":546,"range":{"start_line":546,"start_character":6,"end_line":546,"end_character":14},"in_reply_to":"5f93b717_dd7cd020","updated":"2019-02-13 13:55:42.000000000","message":"Done","commit_id":"32907a663ea3e6d430997fc3dcbb2dea2842b32c"}],"zuul/executor/server.py":[{"author":{"_account_id":16068,"name":"Tobias Henkel","email":"tobias.henkel@bmw.de","username":"tobias.henkel"},"change_message_id":"c7ba08fb9e7d4f67ce3da39594e6688d666457c6","unresolved":false,"context_lines":[{"line_number":1675,"context_line":"            fn_path \u003d os.path.join(plugin_dir, fn)"},{"line_number":1676,"context_line":"            content \u003d open(fn_path).read()"},{"line_number":1677,"context_line":"            new_content \u003d content.replace("},{"line_number":1678,"context_line":"                \"LOG_STREAM_PORT \u003d 19885\","},{"line_number":1679,"context_line":"                \"LOG_STREAM_PORT \u003d %d\" % log_stream_port).replace("},{"line_number":1680,"context_line":"                    \"LOG_STREAM_FILE \u003d \u0027/tmp/console-{log_uuid}.log\u0027\","},{"line_number":1681,"context_line":"                    \"LOG_STREAM_FILE \u003d \u0027%s\u0027\" % log_stream_file)"},{"line_number":1682,"context_line":"            if content !\u003d new_content:"},{"line_number":1683,"context_line":"                with open(fn_path, \"w\") as of:"},{"line_number":1684,"context_line":"                    of.write(new_content)"}],"source_content_type":"text/x-python","patch_set":1,"id":"5f93b717_bda464a7","line":1681,"range":{"start_line":1678,"start_character":0,"end_line":1681,"end_character":63},"updated":"2018-01-30 21:05:29.000000000","message":"I think we rather should take these settings from an ansible var in the module and put them into the inventory instead of hot patching the code. That seems like a hack to me.","commit_id":"32907a663ea3e6d430997fc3dcbb2dea2842b32c"},{"author":{"_account_id":9311,"name":"Tristan Cacqueray","email":"tdecacqu@redhat.com","username":"tristanC"},"change_message_id":"cf76060e6bda2420f46763401c2acf5bba846e93","unresolved":false,"context_lines":[{"line_number":1675,"context_line":"            fn_path \u003d os.path.join(plugin_dir, fn)"},{"line_number":1676,"context_line":"            content \u003d open(fn_path).read()"},{"line_number":1677,"context_line":"            new_content \u003d content.replace("},{"line_number":1678,"context_line":"                \"LOG_STREAM_PORT \u003d 19885\","},{"line_number":1679,"context_line":"                \"LOG_STREAM_PORT \u003d %d\" % log_stream_port).replace("},{"line_number":1680,"context_line":"                    \"LOG_STREAM_FILE \u003d \u0027/tmp/console-{log_uuid}.log\u0027\","},{"line_number":1681,"context_line":"                    \"LOG_STREAM_FILE \u003d \u0027%s\u0027\" % log_stream_file)"},{"line_number":1682,"context_line":"            if content !\u003d new_content:"},{"line_number":1683,"context_line":"                with open(fn_path, \"w\") as of:"},{"line_number":1684,"context_line":"                    of.write(new_content)"}],"source_content_type":"text/x-python","patch_set":1,"id":"9fdfeff1_2c3fbc25","line":1681,"range":{"start_line":1678,"start_character":0,"end_line":1681,"end_character":63},"in_reply_to":"5f93b717_bda464a7","updated":"2019-02-14 04:56:08.000000000","message":"I couldn\u0027t find any documentation or example of how to access inventory/hostvars from a module. I also tried to load the ansible.cfg or through os.environ, but it doesn\u0027t work when the task is running on a remote host.","commit_id":"32907a663ea3e6d430997fc3dcbb2dea2842b32c"},{"author":{"_account_id":16068,"name":"Tobias Henkel","email":"tobias.henkel@bmw.de","username":"tobias.henkel"},"change_message_id":"9b2d0da0ba31e154a619484ff1081d2f524ef0f4","unresolved":false,"context_lines":[{"line_number":1675,"context_line":"            fn_path \u003d os.path.join(plugin_dir, fn)"},{"line_number":1676,"context_line":"            content \u003d open(fn_path).read()"},{"line_number":1677,"context_line":"            new_content \u003d content.replace("},{"line_number":1678,"context_line":"                \"LOG_STREAM_PORT \u003d 19885\","},{"line_number":1679,"context_line":"                \"LOG_STREAM_PORT \u003d %d\" % log_stream_port).replace("},{"line_number":1680,"context_line":"                    \"LOG_STREAM_FILE \u003d \u0027/tmp/console-{log_uuid}.log\u0027\","},{"line_number":1681,"context_line":"                    \"LOG_STREAM_FILE \u003d \u0027%s\u0027\" % log_stream_file)"},{"line_number":1682,"context_line":"            if content !\u003d new_content:"},{"line_number":1683,"context_line":"                with open(fn_path, \"w\") as of:"},{"line_number":1684,"context_line":"                    of.write(new_content)"}],"source_content_type":"text/x-python","patch_set":1,"id":"dfbec78f_4cc34239","line":1681,"range":{"start_line":1678,"start_character":0,"end_line":1681,"end_character":63},"in_reply_to":"9fdfeff1_2c3fbc25","updated":"2019-05-11 17:35:52.000000000","message":"The action plugin already injects the log uuid [1]. In the same place you can take the port and file from an environment variable and inject it to the command module where it can be used [2]. Something similar can be done with the zuul_stream module. In this case you might need to handle this in the normal plugin [3].\n\n[1] https://opendev.org/zuul/zuul/src/branch/master/zuul/ansible/base/actiongeneral/command.py#L27\n[2] https://opendev.org/zuul/zuul/src/branch/master/zuul/ansible/base/library/command.py#L581\n[3] https://opendev.org/zuul/zuul/src/branch/master/zuul/ansible/base/action/normal.py","commit_id":"32907a663ea3e6d430997fc3dcbb2dea2842b32c"}]}
