Commit Graph

15 Commits (6d69956f83172f5e6b15103e7203ea0d0cce87b4)

Author SHA1 Message Date
Toshio Kuratomi 255c4b01a8 Remove duplicate documentation fields 2016-12-08 11:33:46 -05:00
Guido Günther 13deae9b8f zypper: Add returncode to result
This will be used in integration tssts and makes the whole thing
more similar to the yum module.
2016-12-08 11:33:37 -05:00
Robin Roth 85f2165273 better cope with rpm not returning package name
if the rpm query is missing a package name (or giving some error): fail soft

before the patch: the module fails because the installed_state dict is missing the package name

after the patch: the missing package is assumed to not be in the correct state and is installed/removed with zypper
2016-12-08 11:33:33 -05:00
M0ses a1dbb83075 fix errorhandling in zypper.py module
package_latest was calling package_present but did not care
about the return code so errors in package_present were hidden
and everthing look ok on the console when zypper update did not fail,
but no packages where installed.
2016-12-08 11:33:29 -05:00
Alexander Gubin 3ccc50fcd5 zypper: Add local/remote rpm installation
Add remote rpm example
2016-12-08 11:33:06 -05:00
Greg DeKoenigsberg c65a612d1f Changes to author formatting, remove emails 2016-12-08 11:32:51 -05:00
Brian Coca d344a3fde3 more string corrections 2016-12-08 11:32:39 -05:00
Brian Coca 0ed579ddd7 doc update for zypper 2016-12-08 11:32:33 -05:00
Gregory Haynes 960b0f478f Add type property to zypper
To install patterns and other package types a type parameter needs to be
specified to zypper.
2016-12-08 11:32:33 -05:00
Robin Roth 4f0e1c850c fixed tab/space mix 2016-12-08 11:32:32 -05:00
Robin Roth 32310a43ae fix local change 2016-12-08 11:32:32 -05:00
Robin Roth e33875e382 Allow multiple versions in rpm state
Fix bug in ansible get_package_state and get_current_version that breaks when there are multiple versions of a package installed and there is a list of packages to install.
The previous implementation used 'zip' to match requested names to installed names which fails, because rpm outputs multiple lines per package when there are multiple versions.

Testcase: Install opensuse, install multiple kernel versions (happens by update)
Before patch: calling
zypper: state=present for name={{item}}
with_items:
  - kernel-desktop
  - git

leads to ansible aborting.
After the patch ansible performs as expected and makes sure both packages are present.
Also the last version number is used for further update information in this version (before if only one package name was given the oldest version number was used).
2016-12-08 11:32:32 -05:00
Alexander Gubin 117ae098ef zypper: Fix gpg check option for state=latest. --no-gpg-checks is used in new and old zypper versions 2016-12-08 11:32:22 -05:00
Artem Chernikov b4c6b81619 Fixing SuSE to SUSE as latter is the right one since some time 2016-12-08 11:32:20 -05:00
Michael DeHaan 7d6ceb4f06 Reorganization. 2016-12-08 11:32:19 -05:00