So I am trying to run a playbook from Ansible Tower that I have already successfully run from the command line of an ansible server. However, when trying to run this playbook as a template in Ansible Tower, I get an ssh error saying that the public/rivate key pair does not exist. In order to authenticate to the server, you need to provide the username and password. I was able to do this from this command from the ansible server to successfully run the playbook, by passing the username and prompting for a password to be entered to authenticate to the server.
sudo ansible-playbook ./playbooks/dev/vms-create.yml --user root --ask-pass -i ./inventory/hosts
In Ansible Tower I created an vault password in the credentials section to include the password needed to authenticate to the server. But, I am not able to tell the template to pass the username and password to the server before running the playbook the way I was with the server, with the command that I provided above.
Is there a way that I can include the username and password within the playbook itself? I have an encrypted password file used to pull the password into the main playbook, but I think that I need to pass the credentials to the server before attempting to run the playbook, and I am not sure how to do this through Ansible Tower.