salt.modules.yumpkg5

### Navigation

- index
- modules |
- next |
- previous |
- « SaltStack.org |
- Documentation home
- Full list of builtin execution modules »

# salt.modules.yumpkg5

Support for YUM

`salt.modules.yumpkg5.` `available_version`(name)

  The available version of the package in the repository

  CLI Example:

      salt '*' pkg.available_version <package name>

`salt.modules.yumpkg5.` `install`(name, refresh=False, repo='', skip_verify=False, source=None, **kwargs)

  Install the passed package

  name
    The name of the package to be installed
  refresh
    Clean out the yum database before executing
  repo
    Specify a package repository from which to install the package (e.g., `yum --enablerepo=somerepo`)
  skip_verify
    Skip the GPG verification check (e.g., `--nogpgcheck`)

  Return a dict containing the new package names and versions:

      {'<package>': {'old': '<old-version>',
                     'new': '<new-version>']}

  CLI Example:

      salt '*' pkg.install <package name>

`salt.modules.yumpkg5.` `list_pkgs`()

  List the packages currently installed in a dict:

      {'<package_name>': '<version>'}

  CLI Example:

      salt '*' pkg.list_pkgs

`salt.modules.yumpkg5.` `list_upgrades`()

  Check whether or not an upgrade is available for all packages

  CLI Example:

      salt '*' pkg.list_upgrades

`salt.modules.yumpkg5.` `purge`(pkg)

  Yum does not have a purge, this function calls remove

  Return a list containing the removed packages:

  CLI Example:

      salt '*' pkg.purge <package name>

`salt.modules.yumpkg5.` `refresh_db`()

  Since yum refreshes the database automatically, this runs a yum clean, so that the next yum operation will have a clean database

  CLI Example:

      salt '*' pkg.refresh_db

`salt.modules.yumpkg5.` `remove`(pkg)

  Remove a single package with yum remove

  Return a list containing the removed packages:

  CLI Example:

      salt '*' pkg.remove <package name>

`salt.modules.yumpkg5.` `upgrade`()

  Run a full system upgrade, a yum upgrade

  Return a dict containing the new package names and versions:

      {'<package>': {'old': '<old-version>',
                 'new': '<new-version>']}

  CLI Example:

      salt '*' pkg.upgrade

`salt.modules.yumpkg5.` `upgrade_available`(name)

  Check whether or not an upgrade is available for a given package

  CLI Example:

      salt '*' pkg.upgrade_available <package name>

`salt.modules.yumpkg5.` `version`(name)

  Returns a version if the package is installed, else returns an empty string

  CLI Example:

      salt '*' pkg.version <package name>

## Comments

comments powered by Disqus

### Navigation

- index
- modules |
- next |
- previous |
- « SaltStack.org |
- Documentation home
- Full list of builtin execution modules »