All pastes #428814 Raw Edit

Miscellany

public text v1 · immutable
·published 2007-04-07 20:58 UTC
rendered paste body
in classes/account.pp:
define account($homeroot="/home", $uid, $group=$name, $ingroups="users", $fullname=$name, $keygen=false, $ensure=present) {
                                                               
    user { $name:
        uid => $uid,
        gid => $name,
        comment => $fullname,
        home => "${homeroot}/$name",
        shell => "/bin/bash",
        ensure => $ensure,
        #groups => $ingroups,
        allowdupe => false,
        require => Group[$name]


...
} 
in classes/accounts.pp:
class accounts {

  account { "micah": uid => 1001;
            "pietro" uid => 1005; }
...
}
in site.pp:
node vhost inherits base {

  include accounts