New in version 2.7.
Parameter | Choices/Defaults | Comments |
---|---|---|
name
string
/ required
|
The name of the config setting to manage.
See https://chocolatey.org/docs/chocolatey-configuration for a list of valid configuration settings that can be changed.
Any config values that contain encrypted values like a password are not idempotent as the plaintext value cannot be read.
|
|
state
string
|
|
When
absent , it will ensure the setting is unset or blank.When
present , it will ensure the setting is set to the value of value. |
value
string
|
Used when
state=present that contains the value to set for the config setting.Cannot be null or an empty string, use
state=absent to unset a config value instead. |
See also
The official documentation on the win_chocolatey module.
The official documentation on the win_chocolatey_facts module.
The official documentation on the win_chocolatey_feature module.
The official documentation on the win_chocolatey_source module.
- name: Set the cache location
win_chocolatey_config:
name: cacheLocation
state: present
value: D:\chocolatey_temp
- name: Unset the cache location
win_chocolatey_config:
name: cacheLocation
state: absent
This module is not guaranteed to have a backwards compatible interface. [preview]
This module is maintained by the Ansible Community. [community]
Jordan Borean (@jborean93)
Hint
If you notice any issues in this documentation you can edit this document to improve it.