New in version 2.3.
Parameter | Choices/Defaults | Comments |
---|---|---|
name | Name of the package to install, upgrade, or remove. | |
recurse bool |
| When removing a package, also remove its dependencies, provided that they are not required by other packages and were not explicitly installed by a user. |
state |
| Desired state of the package. |
update_cache bool |
| Whether or not to refresh the master package lists. This can be run as part of a package installation or as a separate step. |
upgrade bool |
| Whether or not to upgrade whole system |
# Install package foo - xbps: name=foo state=present # Upgrade package foo - xbps: name=foo state=latest update_cache=yes # Remove packages foo and bar - xbps: name=foo,bar state=absent # Recursively remove package foo - xbps: name=foo state=absent recurse=yes # Update package cache - xbps: update_cache=yes # Upgrade packages - xbps: upgrade=yes
Common return values are documented here, the following are the fields unique to this module:
Key | Returned | Description |
---|---|---|
msg string | success | Message about results Sample: System Upgraded |
packages list | success | Packages that are affected/would be affected Sample: ['ansible'] |
This module is flagged as preview which means that it is not guaranteed to have a backwards compatible interface.
This module is flagged as community which means that it is maintained by the Ansible Community. See Module Maintenance & Support for more info.
For a list of other modules that are also maintained by the Ansible Community, see here.
Hint
If you notice any issues in this documentation you can edit this document to improve it.
© 2012–2018 Michael DeHaan
© 2018 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/2.7/modules/xbps_module.html