I\'m starting out with ansible and I\'m looking for a way to create a boilerplate project on the server and on the local environment with ansible playbooks.
I want to us
If you cannot do/allow localhost SSH, you can split the playbook on local actions and remote actions.
The connection: local
says to not use SSH for a playbook, as shown here: http://docs.ansible.com/ansible/playbooks_delegation.html#local-playbooks
Example:
# myplaybook.yml
- hosts: remote_machines
tasks:
- debug: msg="do stuff in the remote machines"
- hosts: 127.0.0.1
connection: local
tasks:
- debug: msg="ran in local ansible machine"
- hosts: remote_machines
tasks:
- debug: msg="do more stuff in remote machines"