Define automation target hosts in your inventory files
Ansible Automation Platform works against a list of managed nodes or hosts in your infrastructure that are logically organized, using an inventory file. The installer inventory can specify your installation scenario and describe host deployments to Ansible.
An inventory file enables Ansible to manage a large number of hosts with a single command. Inventories also help you automate more efficiently by reducing the number of command line options you have to specify. Inventories are divided into groups and these groups contain the hosts. Groups can be sourced manually, by entering host names into automation controller, or from one of its supported cloud providers.
If you have a custom dynamic inventory script, or a cloud provider that is not yet supported natively in automation controller, you can also import that into automation controller.
From the navigation panel, select . The Inventories window displays a list of the inventories that are currently available.
The Inventory details page includes:
- Name: The inventory name.
- Status
The statuses are:
- Success: When the inventory source sync completed successfully
- Disabled: No inventory source added to the inventory
- Error: When the inventory source sync completed with error
- Type: Identifies whether it is a standard inventory, a Smart inventory, or a constructed inventory.
- Organization: The organization to which the inventory belongs. The following actions are available for the selected inventory:
- Edit
: Edit the properties for the selected inventory - Duplicate
: Makes a copy of an existing inventory as a template for creating a new one - Delete inventory: Delete the selected inventory
- Edit
Click the Inventory name to display the Details page for the selected inventory, which shows the inventory’s groups and hosts.
- Define a collection of hosts with Smart Inventories
Smart Inventories are collections of hosts defined by a stored search that can be viewed such as a standard inventory and can be easily used with job runs. Organization administrators have admin permission for inventories in their organization and can create Smart Inventories. - Configure supported inventory plugin templates
After upgrade to 4.x, existing configurations are migrated to the new format that produces an inventory output compatible with earlier versions. Use the following templates to aid in migrating your inventories to the new style inventory plugin output. - Create dynamic groups with constructed inventories
You can create a new inventory (called a constructed inventory) from a list of input inventories. - Generate dynamic data from external sources with inventory plugins
Automation controller uses inventory plugins to dynamically generate inventory data from external sources. These plugins enable automation controller to integrate with cloud providers, virtualization platforms, and other external systems to retrieve up-to-date information about managed nodes. - Add a source to an inventory
Use the following procedure to add a source to an inventory. When you add a source to an inventory, the system creates a new group for that source. - Run ad hoc commands against a host in an inventory
Learn how to run ad hoc commands against hosts in an inventory. - Import your inventory file from source control
With automation controller you can select an inventory file from source control, rather than creating one from scratch.