New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[RFE] Add debugging facilities for EmbeddedAnsible (w/ansible-runner) #20243
Comments
I realize that this RFE is for the general case, however if we know specific cases can be solved by looking at data from the directory, can we code that in?
So in this example, what exactly in the directory is noticable, and if that noticable thing is well defined, then I think we can code up fetching that information as part of the Ansible::Runner run itself. Asmittedly, this doesn't really solve the general case, but IMO, the general case is the safety net, but "known" cases should be coded for. |
In this case, generally you are looking at the
Or did we write the proper args to (also, FYI: |
This issue has been automatically marked as stale because it has not been updated for at least 3 months. If you can still reproduce this issue on the current release or on Thank you for all your contributions! More information about the ManageIQ triage process can be found in the triage process documentation. |
There is very little transparency with
EmbeddedAnsible
now that we are usingansible-runner
directly instead of deferring toAnsibleTower
/AWX
. Currently, if something goes wrong, unless it is available in the output for the ansible STDOUT/JSON output, it won't be made apparent to the end user via the UI or even the logs. Even still, it is possible that even if there was STDOUT/JSON output, it won't make it to the UI if the playbook failed/timedout, which is even worse as that information is valuable in troubleshooting the root cause.An example of this is a misconfigured SSH auth might cause the playbook run in
ansible-runner
to timeout when asking for a SSH password to auth with for a given host, but that might not be reflected in the output presented to the user, and is only noticable when looking at theansible-runner
directory that was generated for that given run.A temp solution for debugging the above scenario is to comment out this line:
manageiq/lib/ansible/runner/response_async.rb
Line 37 in 44fae84
Restart the appliance, and then looking at the
/tmp
directory to view the artifacts of the given run in question (which is usually in a generated/tmp/ansible-runner*
dir and is not easy to track down, and definitely not an appropriate solution for a production environment).Simply a
DEBUG
toggle might be a decent first step that would avoid running thecleanup_filesystem!
command on that given run, and allow for inspection to determine further action. Taking it further, presenting that data in the UI might also avoid needing to SSH, but possible just making this an option for admins might be the more secure option to start and determine a more tactical approach for end users in the future.The text was updated successfully, but these errors were encountered: