Before you want to try this on your local, here are requirements
- A public key in .ssh/id_rsa.pub in your home directory
- Directly download Virtualbox and install, or use homebrew
brew install --cask virtualbox
- Vagrant
brew install --cask vagrant
- Ansible
brew install ansible
cd getting-started-with-ansible
vagrant up
Let's ssh into two guest VMs
Ping two guest VMs
ansible all -i inventory.yaml -m ping -u ci
Check current directory after login
ansible all -i inventory.yaml -m shell -a "pwd" -u ci
See all available Ansible modules
Execute playbook to install Docker on guest VMs
ansible-playbook -i inventory.yaml playbook.yml