Forge Home

122,956,976 downloads

20,444 latest version

1.9 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

  • 8.0.0 (latest)
  • 7.0.2
  • 7.0.1
  • 7.0.0
  • 6.0.0
  • 5.0.0
  • 4.2.0
  • 4.1.0
  • 4.0.0
  • 3.1.0
  • 3.0.9
  • 3.0.8
  • 3.0.7
  • 3.0.6
  • 3.0.5
  • 3.0.4
  • 3.0.3
  • 3.0.2
  • 3.0.1
  • 3.0.0
  • 2.4.3
  • 2.4.2
  • 2.4.1
  • 2.4.0
  • 2.3.0
  • 2.2.0
  • 2.1.0
  • 2.0.9
  • 2.0.8
  • 2.0.7
  • 2.0.6
  • 2.0.5
  • 2.0.4
  • 2.0.3
  • 2.0.2
  • 2.0.1
  • 2.0.0
  • 1.0.2
  • 1.0.1
  • 1.0.0
released Jul 27th 2012

Start using this module

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

Add this module to your Puppetfile:

mod 'saz-sudo', '2.0.3'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add saz-sudo
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install saz-sudo --version 2.0.3

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
Tags: sudo

Documentation

saz/sudo — version 2.0.3 Jul 27th 2012

puppet-sudo

Manage sudo configuration via Puppet

Usage

Install sudo with default sudoers

    class { 'sudo': }

Adding sudoers configuration snippet

    class { 'sudo': }
    sudo::conf { 'web':
      source => 'puppet:///files/etc/sudoers.d/web',
    }
    sudo::conf { 'admins':
      priority => 10,
      content  => "%admins ALL=(ALL) NOPASSWD: ALL\n",
    }
    sudo::conf { 'joe':
      priority => 60,
      source   => 'puppet:///files/etc/sudoers.d/users/joed',
    }

sudo::conf notes

  • You can pass template() through content parameter.
  • One of content or source must be set.
  • content values must include a \n and be enclosed in double quotes

Additional class parameters

  • ensure: present or absent, default: present
  • autoupgrade: true or false, default: false
  • package: string, default: OS specific. Set package name, if platform is not supported.
  • config_file: string, default: OS specific. Set config_file, if platform is not supported.
  • config_file_replace: true or false, default: true. Replace config file with module config file.
  • config_dir: string, default: OS specific. Set config_dir, if platform is not supported.
  • source: string, default: OS specific. Set source, if platform is not supported.

sudo::conf parameters

  • ensure: present or absent, default: present
  • priority: number, default: 10
  • content: string, default: undef
  • source: string, default: undef
  • sudo_config_dir: string, default: OS specific. Set sudo_config_dir, if platform is not supported.