A Puppet Module that makes it easy to include Microsoft packages for Linux operating systems.

Angelo Italiano



1,084 latest version

5.0 quality score

Version information

  • 0.1.1 (latest)
  • 0.1.0
released Jun 4th 2020
This version is compatible with:
  • Puppet Enterprise 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
  • CentOS

Start using this module


aitalian/mspackages — version 0.1.1 Jun 4th 2020


A Puppet Module that makes it easy to include Microsoft packages for Linux operating systems.

Available on PuppetForge.

Table of Contents

  1. Description
  2. Requirements
  3. Usage
  4. Development


This module adds the Linux Software Repository for Microsoft Products based on distribution, and then installs the given package(s) with the environment variable ACCEPT_EULA=Y set.

Installing Microsoft packages introduces an interactive EULA acceptance prompt; since Puppet runs are non-interactive, an environment variable can be set to implicitly accept the EULA and bypass the prompt. This is possible by using a new resource type introduced with this module: mspackages. Traditional usage of Puppet's package resource type does not support passing environment variables (for reference, see PUP-1526 where this request is outstanding).

This module was developed specifically to install the Microsoft ODBC Driver for SQL Server on Linux, which prompts to accept the EULA, however, any package available for the target distribution is supported.

Disclaimer: You are responsible for reviewing the EULA applicable to the software you are agreeing to install.


  • Puppet >= 4.1.0 or Puppet Enterprise >= 2016.4.x
  • puppetlabs/stdlib (>= 4.13.0)
  • puppetlabs/apt >= 2.3.0 for Debian-based distributions
  • puppetlabs/yumrepo_core >= 1.0.0 for RedHat-based distributions
  • Linux OS: RedHat, CentOS, Debian, Ubuntu

For complete up-to-date requirements, see metadata.json.


To begin, you first need to include the module in your Puppetfile and run Bolt, r10k or Code Manager, or, install it manually using the Puppet module tool.

Once installed, you can include packages either by defining resources within a manifest or hiera configuration file, and then apply it.

  1. manifest.pp example:
# Add the required Microsoft Packages Repo and
# Install the Linux Microsoft ODBC Driver for MS SQL Server.
mspackages { 'msodbcsql17':
  ensure => present,

or to remove packages:

mspackages { 'msodbcsql17':
  ensure => absent,

On a standalone Debian-based system, you can apply this using a local manifest and Puppet Bolt:

$ cat > Puppetfile << EOF
mod 'puppetlabs/stdlib'
mod 'puppetlabs/apt'
mod 'aitalian/mspackages'

$ cat > manifest.pp << EOF
mspackages { 'msodbcsql17':
  ensure => present,

$ bolt puppetfile install --puppetfile ./Puppetfile

$ puppet apply --modulepath=~/.puppetlabs/bolt/modules manifest.pp
  1. hieradata.yaml example: For node-specific configurations, ensure your manifest.pp includes hiera_include('classes'). You can then update your node configuration as follows:
  - 'mspackages::install'

  - 'msodbcsql17'
  - 'mssql-tools'

or to remove packages:

  - 'mssql-tools'


Pull requests are welcome via GitHub. Additional distribution compatibility can be added in both repository.pp and package.pp. This module was built using the Puppet Development Kit (PDK).