Created
April 28, 2020 05:44
-
-
Save luckylittle/071b43b5f23457c6f66c2a903c99ab22 to your computer and use it in GitHub Desktop.
An example of Red Hat Ansible inventory in the YAML format
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[localhost] | |
localhost ansible_connection = local | |
[datastore] | |
10.20.30.40 # Datastore | |
[portal] | |
10.20.30.50 # Portal | |
[server] | |
10.20.30.60 # Server | |
[filetier] | |
10.20.30.70 # Filetier1 | |
10.20.30.80 # Filetier2 | |
[windows:children] | |
datastore | |
portal | |
server | |
filetier | |
[windows:vars] | |
ansible_become_method = runas | |
ansible_become_user = Administrator | |
ansible_connection = psrp | |
ansible_password = "{{ win_passwd }}" | |
ansible_port = 5985 | |
ansible_psrp_proxy = socks5://localhost:8712 # To create Socks5 tunnel: ssh -D 8712 -i sandbox-bastion-linux.pem [email protected] | |
ansible_user = lmaly |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
all: | |
children: | |
localhost: | |
hosts: | |
localhost: | |
ansible_connection: local | |
datastore: | |
hosts: | |
10.20.30.40 | |
filetier: | |
hosts: | |
10.20.30.70 | |
10.20.30.80 | |
portal: | |
hosts: | |
10.20.30.50 | |
server: | |
hosts: | |
10.20.30.60 | |
windows: | |
children: | |
datastore: | |
filetier: | |
portal: | |
server: | |
vars: | |
ansible_become_method: runas | |
ansible_become_user: Administrator | |
ansible_connection: psrp | |
ansible_password: "{{ win_passwd }}" | |
ansible_port: 5985 | |
ansible_psrp_proxy: socks5://localhost:8712 # To create Socks5 tunnel: ssh -D 8712 -i sandbox-bastion-linux.pem [email protected] | |
ansible_user: lmaly |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment