summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--manifests/manage.pp12
1 files changed, 8 insertions, 4 deletions
diff --git a/manifests/manage.pp b/manifests/manage.pp
index e0f2d01..d65266d 100644
--- a/manifests/manage.pp
+++ b/manifests/manage.pp
@@ -23,7 +23,7 @@ define user::manage(
$ticket = false) {
$real_groups = $groups ? {
- '' => [ "$title", ],
+ '' => [ "$title", ],
default => $groups,
}
@@ -51,6 +51,8 @@ define user::manage(
}
if $managehome == true {
+ $real_managehome = true
+
if $ensure == 'absent' {
file{ "$real_homedir":
ensure => absent,
@@ -79,6 +81,8 @@ define user::manage(
}
}
} else {
+ $real_managehome = false
+
if $managehome != false {
if !defined(File[$managehome]) {
file { $managehome:
@@ -103,8 +107,8 @@ define user::manage(
}
file{ "$real_homedir":
- ensure => $managehome,
- require => File[$managehome],
+ ensure => $managehome,
+ require => File[$managehome],
}
}
}
@@ -128,7 +132,7 @@ define user::manage(
allowdupe => false,
comment => "$real_name_comment",
home => $real_homedir,
- managehome => $managehome,
+ managehome => $real_managehome,
shell => $real_shell,
groups => $real_groups,
membership => $membership,