Ansible: To use the ‘ssh’ connection type with passwords, you must install the sshpass program”

Question:

Recently I created new roles called spd in my existing project. While other script works fine in the setup. This newly created fails. Please point me to what is going wrong here

deploy-spd.yml

inventory file

Failure

UPDATE:

Answer:

The issue was because of use of attribute ansible_password in /defaults/main.yml. I have maintained lots of variables in this file to be used by script along with attribute ansible_password.

The attribute ansible_password is reserved for use by Ansible. Now I changed the variable name to ansible_pass and it is working fine.

Leave a Reply