diff options
author | Sebastian Gumprich <rndmh3ro@users.noreply.github.com> | 2019-03-21 17:28:50 +0100 |
---|---|---|
committer | Alicia Cozine <879121+acozine@users.noreply.github.com> | 2019-03-21 11:28:50 -0500 |
commit | 72392187734db87719ee6bdde7a0f776c22c47d0 (patch) | |
tree | 268d05d00bc368c146ba8d273948cf01e2b613a3 /docs | |
parent | d1d859f3f03eaea49aea7b882fad1de1b4dd104b (diff) | |
download | ansible-72392187734db87719ee6bdde7a0f776c22c47d0.tar.gz |
Update inventory.rst (#53656)
Diffstat (limited to 'docs')
-rw-r--r-- | docs/docsite/rst/plugins/inventory.rst | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/docs/docsite/rst/plugins/inventory.rst b/docs/docsite/rst/plugins/inventory.rst index a8bb62fac3..30626667a8 100644 --- a/docs/docsite/rst/plugins/inventory.rst +++ b/docs/docsite/rst/plugins/inventory.rst @@ -41,18 +41,18 @@ The only requirement for using an inventory plugin after it is enabled is to pro Ansible will try to use the list of enabled inventory plugins, in order, against each inventory source provided. Once an inventory plugin succeeds at parsing a source, any remaining inventory plugins will be skipped for that source. -To start using an inventory plugin with a YAML configuration source, create a file with the accepted filename schema for the plugin in question, then add ``plugin: plugin_name``. Each plugin documents any naming restrictions. For example, the aws_ec2 inventory plugin: +To start using an inventory plugin with a YAML configuration source, create a file with the accepted filename schema for the plugin in question, then add ``plugin: plugin_name``. Each plugin documents any naming restrictions. For example, the aws_ec2 inventory plugin has to end with ``aws_ec2.(yml|yaml)`` .. code-block:: yaml # demo.aws_ec2.yml plugin: aws_ec2 -Or for the openstack plugin: +Or for the openstack plugin the file has to be called ``clouds.yml`` or ``openstack.(yml|yaml)``: .. code-block:: yaml - # clouds.yml + # clouds.yml or openstack.(yml|yaml) plugin: openstack The ``auto`` inventory plugin is enabled by default and works by using the ``plugin`` field to indicate the plugin that should attempt to parse it. You can configure the whitelist/precedence of inventory plugins used to parse source using the `ansible.cfg` ['inventory'] ``enable_plugins`` list. After enabling the plugin and providing any required options you can view the populated inventory with ``ansible-inventory -i demo.aws_ec2.yml --graph``: |