Change location of hosts file
-
create your own ansible.cfg
[defaults]
inventory = /path/to/hosts
Ping all hosts
ansible all -m ping --private-key private.pem -u ec2-user
Change location of hosts file
create your own ansible.cfg
[defaults]
inventory = /path/to/hosts
Ping all hosts
ansible all -m ping --private-key private.pem -u ec2-user