summaryrefslogtreecommitdiff
path: root/modules/profiles/manifests/base.pp
blob: 044fbddeeb85f33aa1c67baf1675b98fbb40cfc3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
class profiles::base (
) {
  # ensure admin users for this container
  $admins = hiera('admins')

  $admins.each |String $username| {
    notice("Admin user ${username}")
    $user = hiera('users')[$username]
    group { $user['username']:
      ensure => present,
    } ->
    user { $user['username']:
      ensure   => present,
      comment  => $user['fullname'],
      gid      => $user['username'],
      groups   => ['sudo', 'adm'],
      password => $user['password'],
      uid      => $user['uid'],
    }
  }
}