chocolatey.chocolatey.win_chocolatey_source – Manages Chocolatey sources

From Get docs
Ansible/docs/2.11/collections/chocolatey/chocolatey/win chocolatey source module


chocolatey.chocolatey.win_chocolatey_source – Manages Chocolatey sources

Note

This plugin is part of the chocolatey.chocolatey collection (version 1.0.2).

To install it use: ansible-galaxy collection install chocolatey.chocolatey.

To use it in a playbook, specify: chocolatey.chocolatey.win_chocolatey_source.


New in version 2.7: of chocolatey.chocolatey


Synopsis

  • Used to managed Chocolatey sources configured on the client.
  • Requires Chocolatey to be already installed on the remote host.

Parameters

Parameter Choices/Defaults Comments

admin_only

boolean

  • no
  • yes

Makes the source visible to Administrators only.

Requires Chocolatey >= 0.10.8.

When creating a new source, this defaults to no.

allow_self_service

boolean

  • no
  • yes

Allow the source to be used with self-service

Requires Chocolatey >= 0.10.4.

When creating a new source, this defaults to no.

bypass_proxy

boolean

  • no
  • yes

Bypass the proxy when using this source.

Requires Chocolatey >= 0.10.4.

When creating a new source, this defaults to no.

certificate

string

The path to a .pfx file to use for X509 authenticated feeds.

Requires Chocolatey >= 0.9.10.

certificate_password

string

The password for certificate if required.

Requires Chocolatey >= 0.9.10.

name

string / required

The name of the source to configure.

priority

integer

The priority order of this source compared to other sources, lower is better.

All priorities above 0 will be evaluated first, then zero-based values will be evaluated in config file order.

Requires Chocolatey >= 0.9.9.9.

When creating a new source, this defaults to 0.

source

string

The file/folder/url of the source.

Required when state is present or disabled and the source does not already exist.

source_password

string

The password for source_username.

Required if source_username is set.

source_username

string

The username used to access source.

state

string

  • absent
  • disabled
  • present

When absent, will remove the source.

When disabled, will ensure the source exists but is disabled.

When present, will ensure the source exists and is enabled.

update_password

string

  • always

  • on_create

When always, the module will always set the password and report a change if certificate_password or source_password is set.

When on_create, the module will only set the password if the source is being created.



See Also

See also

win_chocolatey
The official documentation on the win_chocolatey module.
win_chocolatey_config
The official documentation on the win_chocolatey_config module.
win_chocolatey_facts
The official documentation on the win_chocolatey_facts module.
win_chocolatey_feature
The official documentation on the win_chocolatey_feature module.


Examples

- name: Remove the default public source
  win_chocolatey_source:
    name: chocolatey
    state: absent

- name: Add new internal source
  win_chocolatey_source:
    name: internal repo
    state: present
    source: http://chocolatey-server/chocolatey

- name: Create HTTP source with credentials
  win_chocolatey_source:
    name: internal repo
    state: present
    source: https://chocolatey-server/chocolatey
    source_username: username
    source_password: password

- name: Disable Chocolatey source
  win_chocolatey_source:
    name: chocolatey
    state: disabled

Authors

  • Jordan Borean (@jborean93)

© 2012–2018 Michael DeHaan
© 2018–2021 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/2.11/collections/chocolatey/chocolatey/win_chocolatey_source_module.html