Commit Graph

91 Commits (588b20c012d0f1289d2199b18ce506067cd20394)

Author SHA1 Message Date
Patrik Lundin 3f93367579 openbsd_pkg: Use ansible run_command().
This fixes an asterisk glob problem in get_package_state() where a file
in /root/ could cause shell expansion if it matched the package name.
The actual problem is solved by running with shell=False.
11 years ago
Michael DeHaan f4b1e426ea Merge pull request #3379 from serenecloud/devel
Return a friendly error message if aptitude isn't installed
11 years ago
Michael DeHaan 6aa1ecbc30 Merge pull request #3493 from eest/openbsd_pkg-fixes
openbsd_pkg corner case fixes
11 years ago
Michael DeHaan 0bd8935899 Merge pull request #3515 from neomantra/apt_repository
apt_repository: enhance documentation
11 years ago
Michael DeHaan fa9635478b Fixing your YAML Seth :) 11 years ago
Seth Vidal 81940c8b11 add examples for yum: state=latest name=* 11 years ago
Seth Vidal 7216a2b169 add a '*' option for name to state=latest to do a global update 11 years ago
Evan Wies 01fc2b61dc apt_repository: enhance documentation 11 years ago
Patrik Lundin 1b08da26fd openbsd_pkg: some whitespace cleanup. 11 years ago
Patrik Lundin af52cd6ec1 openbsd_pkg: sync package_latest().
This diff syncs package_latest() with the changes to package_present().
I have not managed to figure out how to handle the cornercases where
stderr is set but the command has not failed, so leave a FIXME blob for
other adventurers.
11 years ago
Patrik Lundin 0e4e6e8a84 openbsd_pkg: Handle another pkg_add gotcha
* Add '-m' to pkg_add incovation to get access to the "packagename-1.0: ok"
  message.
* Watch for that message if we are about to fail because of stderr in
  package_present().
11 years ago
Patrik Lundin a67ea75dec openbsd_pkg: handle pkg_add quirks better.
This fixes a problem when trying to install a package with a specific version
number from a local directory and the local directory is checked after a remote
repository:

Error from http://ftp.eu.openbsd.org/pub/OpenBSD/[...]/packagename-1.0.tgz
ftp: Error retrieving file: 404 Not Found
packagename-1.0: ok
11 years ago
Felix Stuermer b5df29901f Use the force=yes option for apt upgrade actions 11 years ago
Seth Vidal d710201ecc - optimize for the extremely common case of people specifying pkg names which are, ultimately, already installed
on a system here time went from  16s for a series of pkgs to 3s to just
  check that they were installed.
11 years ago
Michael DeHaan ecc2b6e742 Styling: deprecation 11 years ago
Michael DeHaan 257d827c9e Styling: misc pep8 11 years ago
serenecloud a17ca862fb Return a friendly error message if aptitude isn't installed 11 years ago
Jack Kuan a07324c590 Fix the issue of easy_install ignoring virtualenv_site_packages=yes. 11 years ago
Michael DeHaan f3093cbb1a Fixup previous apt_key patch to enable file based modes to work. 11 years ago
James Laska 4311412b44 Correctly load up2date configuration
Previously, a configuration file name of None was being passed into
up2dateInitConfig().  This resulted in a correct configuration import,
but failed to properly save the configuration back to disk in the event
a different serverURL was supplied.  This change removes support for
customizing the up2date filename entirely, and relies on up2date to
choose the default config filename.
11 years ago
Michael DeHaan 727cee509c Merge branch 'PR_add_chdir_to_pip' of git://github.com/y-p/ansible into devel
Conflicts:
	library/packaging/pip
11 years ago
Michael DeHaan 50fa88f28a Merge branch 'fix-apt-purge' of git://github.com/madduck/ansible into purge 11 years ago
Michael DeHaan d9c0a5c37d Revert "now modules can implement with_items list globbing w/o updating"
This reverts commit 4942a06bc2.

Conflicts:

	lib/ansible/runner/__init__.py
11 years ago
martin f. krafft ae42144752 Always assume purged for older python-apt
Older python-apt modules don't export Package.installed_files and there
seems to be no other way to figure out if a package is
removed-but-not-purged, so we just always assume it's purged.

Signed-off-by: martin f. krafft <madduck@madduck.net>
11 years ago
martin f. krafft 420f7d7ac6 Introduce non-purged package status
A package may be removed but not purged with APT. The only way to
identify this state is by looking at the list of installed files of
a package. Even if the package has no files installed, this list will be
non-empty until the package is removed:

  # python -c "import apt; c=apt.Cache(); c.update(); c.open(); p=c['ruby1.8']; print p, p.installed, p.installed_files"
  <Package: name:'ruby1.8' id:1425> None [u'']

  # dpkg --purge ruby1.8
  (Reading database ... 27904 files and directories currently installed.)
  Removing ruby1.8 ...
  Purging configuration files for ruby1.8 ...

  # python -c "import apt; c=apt.Cache(); c.update(); c.open(); p=c['ruby1.8']; print p, p.installed, p.installed_files"
  <Package: name:'ruby1.8' id:1425> None []

See http://bugs.debian.org/712749 too.

If a package is not marked installed but it still 'has_files', then it
should be processed if the request is to purge it.

Signed-off-by: martin f. krafft <madduck@madduck.net>
11 years ago
martin f. krafft 8e37a2bec9 Fix purging of packages
A small error in the reuse of a variable caused packages to never get
purged. This commit fixes that.

Signed-off-by: martin f. krafft <madduck@madduck.net>
11 years ago
Michael DeHaan 31b63b033b Merge conflict 11 years ago
Michael DeHaan 96134d003e Merge remote branch 'origin/devel' into devel 11 years ago
Jesse Keating 86bc2ec08a pkg option of apt is not required
You can use apt module with update_cache and without specifying a
package. Update the docs to reflect this.
11 years ago
Michael DeHaan b4358d1300 Merge branch 'apt_key_file' of git://github.com/veeti/ansible into devel
Conflicts:
	library/packaging/apt_key
11 years ago
Veeti Paananen 77159d21da Add apt_key examples for file and data 11 years ago
Jan-Piet Mens 30d641094b Docs: consistently format playbook EXAMPLES 11 years ago
Michael DeHaan e128e8b563 Merge pull request #3162 from strawlab/apt-key-binary-fix
allow apt-key module to work with binary key
11 years ago
Michael DeHaan 58e8a97e91 Merge pull request #3225 from eest/openbsd_pkg-check_mode
openbsd_pkg: Add check_mode support.
11 years ago
Michael DeHaan 613df1d649 Merge pull request #3213 from veeti/apt_key_data
Document the data argument for apt_key
11 years ago
Michael DeHaan d9f91be34a Merge pull request #3227 from bcoca/modules_wantlist
implementing with_items list globbing made easier for modules
11 years ago
Michael DeHaan f87299842c Merge pull request #3199 from chrishoffman/doc_error
Fixing documentation error
11 years ago
Michael DeHaan 4849539399 Merge pull request #3194 from E-M/patch-2
Fixed Issue #3193 - make rhn_register module compatible with EL 5
11 years ago
Brian Coca 4942a06bc2 now modules can implement with_items list globbing w/o updating
hardcoded lists in ansible code, just add WITH_ITEMS_USES_LIST in a
comment anywhere, and of course, support recieving params as list.

Signed-off-by: Brian Coca <briancoca+dev@gmail.com>
11 years ago
Jan-Piet Mens 5c69918d53 DOCS: standardize on EXAMPLES (a.k.a. Docs-JumboPatch JetLag Edition)
Migrated all examples: in DOCUMENTATION=''' string to standalone EXAMPLES=''' string
  Added deprecation warning to moduledev.rst and remove deprecated example from it
  Fixed up a few typos and uppercased some acronyms.
  add consistency to how EXAMPLES are formatted
11 years ago
Patrik Lundin 9dfc420927 openbsd_pkg: Add check_mode support.
The biggest change has been to package_latest since it was previously
just comparing version numbers before and after an upgrade had run.
We now parse the output from a dry run instead.

Thanks to Johan Belin for triggering the discussion :).
11 years ago
Veeti Paananen 1284bfd742 Add a file argument to apt_key 11 years ago
Veeti Paananen dcb06a2306 Document the data argument for apt_key 11 years ago
Chris Hoffman 8a55210fb6 Removing all the default: null from the documentation 11 years ago
Chris Hoffman 499c7309e3 Fixing documentation error 11 years ago
Edgars M. 46ad4299a8 Fixed Issue #3193 11 years ago
E-M 170a5f36f1 Fixed module name in examples section
Examples showed that modules name is rhnreq_ks, when it actually is rhn_register.
11 years ago
Andrew Straw 94e66ef558 allow apt-key module to work with binary key 11 years ago
Michael DeHaan 41bded178d Rename module 11 years ago
Michael DeHaan 305694a847 Update "added in" version in zypper, update doc name of rhn_register module. 11 years ago