Puppet Class: sudoers
- Defined in:
- manifests/init.pp
Overview
Define global requirements for sudoers
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'manifests/init.pp', line 2
class sudoers {
$rootgroup = $::osfamily ? {
/(Darwin|FreeBSD|Solaris)/ => 'wheel',
default => 'root',
}
@file { '/etc/sudoers.d':
ensure => 'directory',
mode => '0660',
owner => 'root',
group => $rootgroup
}
@file_line { 'include for sudoers.d':
path => '/etc/sudoers',
line => '#includedir /etc/sudoers.d',
match => '^#includedir (\/private)?\/etc\/sudoers\.d$',
}
}
|