aboutsummaryrefslogtreecommitdiff
path: root/modules/base_installation/manifests/users.pp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/base_installation/manifests/users.pp')
-rw-r--r--modules/base_installation/manifests/users.pp8
1 files changed, 8 insertions, 0 deletions
diff --git a/modules/base_installation/manifests/users.pp b/modules/base_installation/manifests/users.pp
index 34df4bd..d0ac449 100644
--- a/modules/base_installation/manifests/users.pp
+++ b/modules/base_installation/manifests/users.pp
@@ -22,6 +22,13 @@ class base_installation::users (
22 22
23 $users.each |$user| { 23 $users.each |$user| {
24 if ($user["username"] != "root") { 24 if ($user["username"] != "root") {
25 unless $user["shell"] == undef or empty($user["shell"]) {
26 ensure_packages([$user["shell"]])
27 $shell = "/bin/${user[shell]}"
28 } else {
29 $shell = undef
30 }
31
25 user { "${user[username]}:${user[userid]}": 32 user { "${user[username]}:${user[userid]}":
26 name => $user[username], 33 name => $user[username],
27 uid => $user[userid], 34 uid => $user[userid],
@@ -30,6 +37,7 @@ class base_installation::users (
30 managehome => true, 37 managehome => true,
31 system => !!$user[system], 38 system => !!$user[system],
32 home => "/home/${user[username]}", 39 home => "/home/${user[username]}",
40 shell => $shell,
33 notify => Exec["remove_password:${user[username]}:${user[userid]}"], 41 notify => Exec["remove_password:${user[username]}:${user[userid]}"],
34 purge_ssh_keys => true 42 purge_ssh_keys => true
35 } 43 }