This repository has been archived by the owner on Jan 6, 2023. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
molecule_vagrant/modules/vagrant.py: Improve error handling (#80)
- Make sure that up() is exiting with either exit_json() or fail_json() - Catch errors for calls to vagrant.conf() and vagrant.status() - Now that the functions up/destroy/halt of the VagrantClient class should all be exiting with proper fail/exit_json, but in the case of the last line of main() is still reached, change the code to use VagrantClient result to avoid the following exception: AttributeError: 'AnsibleModule' object has no attribute 'result' Signed-off-by: Arnaud Patard <apatard@hupstream.com>
- Loading branch information