Forge Home

pin_package

Package Pinning for RHEL and Debian based Distributions

1,950 downloads

783 latest version

5.0 quality score

We run a couple of automated
scans to help you access a
module's quality. Each module is
given a score based on how well
the author has formatted their
code and documentation and
modules are also checked for
malware using VirusTotal.

Please note, the information below
is for guidance only and neither of
these methods should be considered
an endorsement by Puppet.

Version information

  • 0.3.1 (latest)
  • 0.3.0
  • 0.2.1
  • 0.2.0
  • 0.1.0
released Aug 4th 2021
This version is compatible with:
  • Puppet Enterprise 2023.2.x, 2023.1.x, 2023.0.x, 2021.7.x, 2021.6.x, 2021.5.x, 2021.4.x, 2021.3.x, 2021.2.x, 2021.1.x, 2021.0.x, 2019.8.x, 2019.7.x, 2019.5.x, 2019.4.x, 2019.3.x, 2019.2.x, 2019.1.x, 2019.0.x, 2018.1.x, 2017.3.x, 2017.2.x, 2016.4.x
  • Puppet >= 4.10.0 < 8.0.0
  • , , , , ,

Start using this module

  • r10k or Code Manager
  • Bolt
  • Manual installation
  • Direct download

Add this module to your Puppetfile:

mod 'maxadamo-pin_package', '0.3.1'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add maxadamo-pin_package
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install maxadamo-pin_package --version 0.3.1

Direct download is not typically how you would use a Puppet module to manage your infrastructure, but you may want to download the module in order to inspect the code.

Download

Documentation

maxadamo/pin_package — version 0.3.1 Aug 4th 2021

pin_package

Table of Contents

  1. Description
  2. Notes on this version
  3. Usage
  4. Limitations
  5. Development

Description

This module installs packages and forces version pinning on Debian and RedHat based distribution (Debian, Ubuntu, RedHat, CentOS...).

Pinned packages cannot be upgraded, unless they're unpinned or their version number is changed.

Notes on this version

This is a transitioning version and you can still use pin_package or pin_package::pin. The latter will be removed in the coming version.

Usage

Pinning

pin_package { 'apache':
  ensure => '0.5-40';
}

Unpinning

pin_package { 'apache':
  ensure => '0.5-40',
  unpin  => true;
}

Mutual dependencies handling

If you have mutual dependencies issues or if your module leverages the package installation, you can set pin_only to true, and you use the package resource with require against pin_package define. Example:

pin_package { ['salt-minion', 'salt-common']:
  ensure   => $my_version,
  pin_only => true;
}

package { ['salt-minion', 'salt-common']:
  ensure  => $my_version,  # you can also use latest here, because you have already pinned
  require => Pin_package['salt-minion', 'salt-common'];
}

Limitations

  • only Debian/RedHat families are supported: Debian, Ubuntu, RedHat, CentOS...
  • no test available

Development

Feel free to make pull requests and/or open issues on my GitHub Repository

Please make a pull request to add $facts['os']['name'] (or tell me the string to add) for any missing OS, like as Scientific Linux or Oracle Linux

Release Notes/Contributors

Massimiliano Adamo