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:
parent
d5096bc5ef
commit
6b3428b8c2
1 changed files with 2 additions and 1 deletions
|
@ -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']
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue