Skip to content

Instantly share code, notes, and snippets.

@limed
Created November 28, 2011 00:02
Show Gist options
  • Save limed/1398510 to your computer and use it in GitHub Desktop.
Save limed/1398510 to your computer and use it in GitHub Desktop.
adduser example
define adduser ($shell = '/bin/bash', $comment = '', $password = '' ){
$home_prefix = "/home"
user { ${name}:
ensure => present,
gid => ${name},
groups => ${name},
home => ${home_prefix}/${name},
password => ${password},
comment => ${comment},
$shell => ${shell},
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment