Parameter |
Choices/Defaults |
Comments |
arguments
|
|
Any arguments the installer needs to either install or uninstall the package.
If the package is an MSI do not supply the /qn , /log or /norestart arguments.
As of Ansible 2.5, this parameter can be a list of arguments and the module will escape the arguments as necessary, it is recommended to use a string when dealing with MSI packages due to the unique escaping issues with msiexec.
|
creates_path
path
(added in 2.4) |
|
Will check the existance of the path specified and use the result to determine whether the package is already installed.
You can use this in conjunction with product_id and other creates_* .
|
creates_service
(added in 2.4) |
|
Will check the existing of the service specified and use the result to determine whether the package is already installed.
You can use this in conjunction with product_id and other creates_* .
|
creates_version
(added in 2.4) |
|
Will check the file version property of the file at creates_path and use the result to determine whether the package is already installed.
creates_path MUST be set and is a file.
You can use this in conjunction with product_id and other creates_* .
|
expected_return_code
list |
Default:
[0, 3010]
|
One or more return codes from the package installation that indicates success.
Before Ansible 2.4 this was just 0 but since 2.4 this is both 0 and 3010 .
A return code of 3010 usually means that a reboot is required, the reboot_required return value is set if the return code is 3010 .
|
password
|
|
The password for user_name , must be set when user_name is.
aliases: user_password
|
path
|
|
Location of the package to be installed or uninstalled.
This package can either be on the local file system, network share or a url.
If the path is on a network share and the current WinRM transport doesn't support credential delegation, then user_name and user_password must be set to access the file.
There are cases where this file will be copied locally to the server so it can access it, see the notes for more info.
If state=present then this value MUST be set.
If state=absent then this value does not need to be set if product_id is.
|
product_id
|
|
The product id of the installed packaged.
This is used for checking whether the product is already installed and getting the uninstall information if state=absent .
You can find product ids for installed programs in the Windows registry editor either at HKLM:Software\Microsoft\Windows\CurrentVersion\Uninstall or for 32 bit programs at HKLM:Software\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall .
This SHOULD be set when the package is not an MSI, or the path is a url or a network share and credential delegation is not being used. The creates_* options can be used instead but is not recommended.
aliases: productid
|
state
|
Default:
present
|
Whether to install or uninstall the package.
The module uses product_id and whether it exists at the registry path to see whether it needs to install or uninstall the package.
aliases: ensure
|
username
|
|
Username of an account with access to the package if it is located on a file share.
This is only needed if the WinRM transport is over an auth method that does not support credential delegation like Basic or NTLM.
aliases: user_name
|
validate_certs
bool
(added in 2.4) |
|
If no , SSL certificates will not be validated. This should only be used on personally controlled sites using self-signed certificates.
Before Ansible 2.4 this defaulted to no .
|