community.windows.win_feature_info module – Gather information about Windows features
Note
This module is part of the community.windows collection (version 1.10.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 community.windows
.
To use it in a playbook, specify: community.windows.win_feature_info
.
New in version 1.4.0: of community.windows
Parameters
Parameter |
Comments |
---|---|
If specified, this is used to match the Can be a wildcard to match multiple features but the wildcard will only be matched on the If omitted then all features will returned. Default: “*” |
See Also
See also
- ansible.windows.win_feature
The official documentation on the ansible.windows.win_feature module.
Examples
- name: Get info for all installed features
community.windows.win_feature_info:
register: feature_info
- name: Get info for a single feature
community.windows.win_feature_info:
name: DNS
register: feature_info
- name: Find all features that start with 'FS'
ansible.windows.win_feature_info:
name: FS*
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
Whether any features were found based on the criteria specified. Returned: always Sample: true |
|
A list of feature(s) that were found based on the criteria. Will be an empty list if no features were found. Returned: always |
|
A list of privileges that the feature requires and will run with Returned: success |
|
The action to perform once triggered, can be Returned: success Sample: “ADCertificateServicesRole” |
|
Major Version of feature Returned: success Sample: 8 |
|
Minor Version of feature Returned: success Sample: 0 |
|
Numberic Id of feature Returned: success Sample: 16 |
|
BestPracticesModelId for feature Returned: success Sample: “Microsoft/Windows/UpdateServices” |
|
The command line that will be run when a Returned: success Sample: [“Web-Static-Content”, “Web-Default-Doc”] |
|
Depth of Returned: success Sample: 1 |
|
The description of the feature. Returned: success Sample: “Example description of the Windows feature.” |
|
The Display name of feature found. Returned: success Sample: “Active Directory Certificate Services” |
|
The EventQuery for feature This will be Returned: success Sample: “IPAMServer.Events.xml” |
|
The Feature Type of Values will be one of Returned: success Sample: “Feature” |
|
The Install State of Values will be one of Returned: success Sample: “Installed” |
|
Whether the feature by Returned: success Sample: false |
|
Name of feature found. Returned: success Sample: “AD-Certificate” |
|
The parent of feature Returned: success Sample: “PowerShellRoot” |
|
The Path of Returned: success Sample: “WoW64 Support” |
|
Tells if Post Configuration is needed for feature Returned: success Sample: false |
|
Descriptor of Returned: success Sample: “ServerComponent_AD_Certificate” |
|
List of sub features names of feature Returned: success Sample: [“WAS-Process-Model”, “WAS-NET-Environment”, “WAS-Config-APIs”] |
|
The name of the service installed by feature Returned: success Sample: [“iisadmin”, “w3svc”] |
Authors
Larry Lane (@gamethis)