Ansible: Please pip install hvac to use the hashi_vault lookup module.
Error msg:
An unhandled exception occurred while running the lookup plugin 'hashi_vault'.
Error was a <class 'ansible.errors.AnsibleError'>,
original message:
Please pip install hvac to use the hashi_vault lookup module.
Please check Ansible's python environment:
bash
ansible -m debug -a 'var=ansible_playbook_python' localhost
The terminal will show the path of Ansible's env:
localhost | SUCCESS => {
"ansible_playbook_python": "/usr/local/Cellar/ansible/2.6.0/libexec/bin/python2.7"
}
Pip install!
bash
source /usr/local/Celler/ansible/2.6.0/libexec/bin/activate
pip install hvac