Ansible Inventory

  • Configure hosts to run tasks on in a file
  • Can be written using Inventory or YAML syntax
  • Use a dynamic Inventory to populate the inventory file through a inventory source such as AWS

Group Hosts

For grouping Hosts

[homelab]
homelab.nas

[ubuntu]
homelab.compressor
homelab.docker

Inventory Variables

[atlanta]
host1 http_port=80 maxRequestsPerChild=808
host2

[atlanta:vars]
ntp_server=ntp.atlanta.example.com
proxy=proxy.atlanta.example.com