ansible.windows.setup module – Gathers facts about remote hosts
Note
This module is part of the ansible.windows collection (version 2.5.0).
You might already have this collection installed if you are using the ansible
package.
It is not included in ansible-core
.
To check whether it is installed, run ansible-galaxy collection list
.
To install it, use: ansible-galaxy collection install ansible.windows
.
To use it in a playbook, specify: ansible.windows.setup
.
Synopsis
This module is automatically called by playbooks to gather useful variables about remote hosts that can be used in playbooks. It can also be executed directly by
/usr/bin/ansible
to check what variables are available to a host. Ansible provides many facts about the system, automatically.
Parameters
Parameter |
Comments |
---|---|
For internal use Choices:
|
|
Path used for local ansible facts ( The returned fact will be named after the local file (without the extension suffix), e.g. |
|
If supplied, restrict the additional facts collected to the given subset. Can specify a list of values to specify a larger subset. Values can also be used with an initial To avoid collecting even the min subset, specify To collect only specific facts, use Default: |
|
Set the default timeout in seconds for individual fact gathering. Default: |
Notes
Note
More ansible facts will be added with successive releases. If facter is installed, variables from these programs will also be snapshotted into the JSON file for usage in templating. These variables are prefixed with
facter_
so it’s easy to tell their source. All variables are bubbled up to the caller.Some facts may be unavailable if running under a limited account.
For more information about delegated facts, please check https://docs.ansible.com/ansible/latest/user_guide/playbooks_delegation.html#delegating-facts.
See Also
See also
- ansible.windows.setup
Gathers facts about remote hosts.
Examples
- name: run the setup facts
ansible.windows.setup: