New in version 2.0.
- Whatever is required for the package plugins specific for each system.
parameter | required | default | choices | comments |
---|---|---|---|---|
name |
yes | Package name, or package specifier with version, like name-1.0 .Be aware that packages are not always named the same and this module will not 'translate' them per distro. | ||
state |
yes | Whether to install ( present , latest ), or remove (absent ) a package. | ||
use |
no | auto | The required package manager module to use (yum, apt, etc). The default 'auto' will use existing facts or try to autodetect it. You should only use this field if the automatic selection is not working for some reason. |
- name: install the latest version of ntpdate package: name: ntpdate state: latest # This uses a variable as this changes per distribution. - name: remove the apache package package: name: "{{ apache }}" state: absent
Note
This module is flagged as stableinterface which means that the maintainers for this module guarantee that no backward incompatible interface changes will be made.
This module is maintained by those with core commit privileges
For more information on what this means please read Module Support
For help in developing on modules, should you be so inclined, please read Community Information & Contributing, Helping Testing PRs and Developing Modules.