Update README.md

This commit is contained in:
James Tombleson 2019-04-08 08:54:28 -07:00
parent e0b95e9889
commit 07dc29ce41

View File

@ -1,33 +1,32 @@
# Ansible # Ansible
First things first, install ansible Review the installAnsible.sh for quick setup.
```bash Make sure you run the commands out of this folder so things work as desired.
sudo apt-get install ansible
```
## Configuration ## Configuration
[doc](https://docs.ansible.com/ansible/latest/reference_appendices/config.html#ansible-configuration-settings-locations) I have a basic configuration file in place at the root of this folder for anisble to find.
The configuration file
Changes can be made and used in a configuration file which will be searched for in the following order:
ANSIBLE_CONFIG (environment variable if set)
ansible.cfg (in the current directory)
~/.ansible.cfg (in the home directory)
/etc/ansible/ansible.cfg
## Inventory ## Inventory
The default location for inventory should be placed in /etc/ansible/hosts. But you can always overwrite what inventory file is used with the -i flag I have a template file in place that should only be used as a refrence. Make a copy of that file and name it hosts then update that file.
## Testing Inventory
## Cheat Sheet ### Testing Linux devices
Quick notes for ansible via cmd
```bash ```bash
ansible -i \inb ansible linux -i hosts -m ping
``` ```
### Testing Windows devices
```bash
ansible windows -i hosts -m win_ping
```