remove 'include sudo' because this would result in a duplicate definition if you

have in your site_sudo something like:

  class { 'sudo': deploy_sudoers => true }

instead we just declare a class dependency on the file in the define
This commit is contained in:
Micah Anderson 2013-06-22 14:51:50 -04:00
parent d5096bc5ef
commit 6b3428b8c2

View file

@ -3,7 +3,7 @@ define sudo::access (
$user = undef, $user = undef,
$access = 'ALL=(ALL) ALL' $access = 'ALL=(ALL) ALL'
) { ) {
include sudo
if $user == undef { if $user == undef {
$real_user = $name $real_user = $name
} else { } else {
@ -16,5 +16,6 @@ define sudo::access (
group => 0, group => 0,
mode => '0440', mode => '0440',
content => "# THIS FILE IS MANAGED BY PUPPET !\n${real_user} ${access}\n", content => "# THIS FILE IS MANAGED BY PUPPET !\n${real_user} ${access}\n",
require => Class['sudo']
} }
} }