Documentation

win_chocolatey - Installs packages using chocolatey

New in version 1.9.

Synopsis

Options

parameter required default choices comments
allow_empty_checksums
(added in 2.2)
no
    Allow empty Checksums to be used
    force
    no
    • True
    • False
    Forces install of the package (even if it already exists). Using Force will cause ansible to always report that a change was made
    ignore_checksums
    (added in 2.2)
    no
      Ignore Checksums
      ignore_dependencies
      (added in 2.1)
      no
        Ignore dependencies, only install/upgrade the package itself
        install_args
        (added in 2.1)
        no
          Arguments to pass to the native installer
          name
          yes
            Name of the package to be installed
            params
            (added in 2.1)
            no
              Parameters to pass to the package
              source
              no
                Specify source rather than using default chocolatey repository
                state
                no present
                • present
                • absent
                State of the package on the system
                upgrade
                no
                • True
                • False
                If package is already installed it, try to upgrade to the latest version or to the specified version
                version
                no
                  Specific version of the package to be installed
                  Ignored when state == 'absent'

                  Examples

                  # Install git
                  win_chocolatey:
                    name: git
                  
                  # Install notepadplusplus version 6.6
                  win_chocolatey:
                    name: notepadplusplus.install
                    version: '6.6'
                  
                  # Uninstall git
                  win_chocolatey:
                    name: git
                    state: absent
                  
                  # Install git from specified repository
                  win_chocolatey:
                    name: git
                    source: https://someserver/api/v2/
                  

                  Status

                  This module is flagged as preview which means that it is not guaranteed to have a backwards compatible interface.

                  Support

                  This module is supported mainly by the community and is curated by core committers

                  For more information on what this means please read Extras Modules

                  For help in developing on modules, should you be so inclined, please read Community Information & Contributing, Helping Testing PRs and Developing Modules.