Commit Graph

99 Commits (0dbf41e740c6b0fa25989b69ffcd14fba5a55848)

Author SHA1 Message Date
Toshio Kuratomi 05be82183f Add notes about loop squashing and 1.9.2 change to install packages in one yum transaction 2016-12-08 11:23:19 -05:00
Brian Coca e7dc05df11 updated upgrade to a more sensible default as the previous was prone to confusion fixes #1667 2016-12-08 11:23:17 -05:00
Matt Martz a0f5ae8726 Replaced tabbed indentation with spaces for apt module 2016-12-08 11:23:16 -05:00
Toshio Kuratomi 432764b703 Add version that the profilename param was added 2016-12-08 11:23:16 -05:00
verm666 9b3aa0a9d4 This change is in response to issue #133.
The original problem is: apt_repository.py connect to launchpad on
every playbook run. In this patch apt_repository.py checks if required
repository already exists or not. If no - paa will be added, if yes -
just skip actions.
2016-12-08 11:23:14 -05:00
Toshio Kuratomi 9ecd06fb47 Fix apt_repository so that it does not modify the mode of existing repositories 2016-12-08 11:23:12 -05:00
Sebastian Gerhards a979417a4a rhn_register: add support for profilename 2016-12-08 11:23:12 -05:00
Jim Patterson 4185ffc43e Correct check mode for pip in virtualenv.
Fix #412.  Check mode was always returning changed=True for pip
when the target was in a virtualenv.  The code now uses the normal
tests for determining if change status.
2016-12-08 11:23:11 -05:00
Pierre-Louis Bonicoli c366e7acb2 apt_repository: fix file mode
'set_mode_if_different' method should be called on dest filename and after
'atomic_move' method
2016-12-08 11:23:11 -05:00
Toshio Kuratomi bd87c11c2a Read the url in in chunks so that we don't use as much memory for large packages 2016-12-08 11:23:11 -05:00
Toshio Kuratomi 2e7dcf3317 Small cleanups. * Import url(lib|parse|lib2) if needed by the module rather than relying on module_utils.urls to do so. * Remove stdlib modules from requirements * Use the if __name__ conditional for invoking main() 2016-12-08 11:23:11 -05:00
Toshio Kuratomi 88ae201b20 Fix bugs found by @kustodian 2016-12-08 11:23:09 -05:00
Toshio Kuratomi f0f1dc985f Fix incorrect line breaking 2016-12-08 11:23:09 -05:00
Toshio Kuratomi 9f043d9ba8 Further optimizations pointed out by @kustodian in #1516
* Only install yum-utils if needed (b/c we're going to use repoquery)
* Add a warning message explaining that why slower repoquery was used
  rather than yum API.
2016-12-08 11:23:08 -05:00
Toshio Kuratomi ba566501a8 Yum API is faster than calling out to repoquery. Looking through the commit logs it looks like we weren't previously doing that because of commit 14479e6adc
The message there is that Yum API prints an error message if the
rhn-plugin is in use and no rhn-certificate is available.  So instead of
using repoquery in preference always here we use repoquery in preference
if the rhn-plugin is enabled.
2016-12-08 11:23:08 -05:00
az7arul 5ffb677b00 add `include_doc` option 2016-12-08 11:23:08 -05:00
Toshio Kuratomi ada424078b Restore setting cachedir when non-root but don't take a useless cachedir parameter to the function
* Revert "Remove unused code"
  This reverts commit bcfba0c05098696b6e770335870a9c22792fec38.
* Re-add the changes to remove cachedir as a parameter
2016-12-08 11:23:08 -05:00
Greg DeKoenigsberg eb881d7d5d Proper author info for all remaining modules 2016-12-08 11:23:07 -05:00
Edward Torbett 3a4d8f22a6 Renamed previous pkgs variable to installed_pkgs as spotted by @strahinja 2016-12-08 11:23:06 -05:00
Edward Torbett dad26d70fa Corrected pkg to pkgs as noted by @abadger 2016-12-08 11:23:06 -05:00
Edward Torbett 9707a5a95e Added multi package operation to remove as suggested by @abadger. Adding to latest is a little more complex due to '*' support. 2016-12-08 11:23:06 -05:00
Edward Torbett 32180c3c0e Comments by @abadger 2016-12-08 11:23:06 -05:00
Edward Torbett 4b3fff108d Rather than executing yum once per package, execute yum once for all supplied packages. This is necessary when performing a yum upgrade involving multiple dependent packages installed from RPM, for example when upgrading from PostgreSQL 9.0.11 to 9.0.21 on a Red Hat server. 2016-12-08 11:23:06 -05:00
Brian Coca 61054921cf updated package examples 2016-12-08 11:23:05 -05:00
Brian Coca d4d362b475 corrected copyright ... does a copied the copyrightnotice require copyright? 2016-12-08 11:23:05 -05:00
Brian Coca 0f30122750 may root help us all 2016-12-08 11:23:05 -05:00
Demian Gemperli 1c5cb83ff3 Allow to add build flags for gem installation 2016-12-08 11:23:04 -05:00
Toshio Kuratomi 8976b46888 Import ansible module_utils at bottom of file to not mess with line numbers in tracebacks 2016-12-08 11:23:02 -05:00
Jonathan Mainguy a3f30540ca add :// url support for EL 5 2016-12-08 11:23:02 -05:00
Vasyl Kaigorodov 70235a930b Fix "_is_package_installed() takes exactly 4 arguments, 3 provided" error 2016-12-08 11:23:01 -05:00
Schlueter b3be960d24 Add 'version_added' to state documentation for easy_install resource 2016-12-08 11:23:01 -05:00
Schlueter 9e8ce34031 Correct reference to gem in easy_install resource 2016-12-08 11:23:01 -05:00
Schlueter 58863d3b48 Add Documentation 2016-12-08 11:23:01 -05:00
Schlueter 1fc687b19d Use standard if statement to check state in easy_install resource 2016-12-08 11:23:00 -05:00
Schlueter 1ddf4c2368 Correct pass by object reference issue 2016-12-08 11:23:00 -05:00
Zoltan Kozma 1a6b273a4f - Fixed annoying bug that disablerepo was essentially broken if a package needed updating by state latest. - Replaced some unsafe practice with default parameters. However looking at the code this does not seem to matter much as the calling functions always seem to supply these parameters anyway. 2016-12-08 11:23:00 -05:00
Schlueter e198884280 Add state to easy_install 2016-12-08 11:23:00 -05:00
Semyon Deviatkin 732b26ab23 Fix issue #1230
When virtual package providing only one package, look up status of target package
2016-12-08 11:23:00 -05:00
Brian Coca 831e1d8739 added updated cache time to apt, also started documenting return values 2016-12-08 11:22:58 -05:00
Matt Martz 65508bb21a Python2.4 fixes
* Ignore accelerate.py
* Don't use a lambda or a ternary
2016-12-08 11:22:58 -05:00
Toshio Kuratomi dd02483b26 Explain why the apt module does not do implicit regex matches on package name since this is different than the apt-get command line tool.
Fixes #1258
2016-12-08 11:22:58 -05:00
Dominic Hargreaves 535f0e9b11 apt_key documentation: add a note explaining the benefit of including 'id' 2016-12-08 11:22:58 -05:00
Jonathan Mainguy f662a48de7 Adds the exclude= option to the yum module. Works the same way --exclude does when yum install or yum update 2016-12-08 11:22:57 -05:00
Toshio Kuratomi 9133ae8c55 Allow yum module to take a yaml list of package names and also ", " separated string-list (in addition to comma separated string-list) 2016-12-08 11:22:55 -05:00
James Cammarata 5a0a9d9f72 Add version_added string to new org_id param in rhn_subscription 2016-12-08 11:22:54 -05:00
bugchecker b7b6367ad5 prevent using undefined variable 2016-12-08 11:22:54 -05:00
Brian Coca b6e3ddba9a ifxed error message as code remove the repo r var 2016-12-08 11:22:54 -05:00
David Wittman be0d28a4ac Set disabled repos before enabled repos
The ordering of disabling/enabling yum repositories matters, and
the yum module was mixing and matching the order. Specifically,
when yum-utils isn't installed, the codepath which uses the yum
python module was incorrectly ordering enabling and disabling.

The preferred order is to disable repositories and then enable them
to prevent clobbering. This was previously discussed in
ansible/ansible#5255 and incompletely addressed in 0cca4a3.
2016-12-08 11:22:53 -05:00
Niels de Vos ca9fd7e136 redhat_subscription: add the `org_id` parameter
When subscribing a system with an activationkey, it seems (sometimes?)
required to pass the "--org <number>" parameter to subscription-manager.
Activation Keys can be created through the Red Hat Customer Portal, and
a subscription can be attached to those. This makes is easy to register
systems without passing username/passwords around.

The organisation ID can be retrieved by executing the following command
on a registered system (*not* the account number):

  # subscription-manager identity

URL: https://access.redhat.com/management/activation_keys
Signed-off-by: Niels de Vos <ndevos@redhat.com>
Reviewed-by: Ken Dreyer <kdreyer@redhat.com>
2016-12-08 11:22:53 -05:00
Michael Scherer 1559bccdb3 Remove unused option in the repoquery call
Citing the man page:
       -q, --query
              For rpmquery compatibility, doesn't do anything.
2016-12-08 11:22:53 -05:00