Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

feature/allowdupe - fixes #23 #24

Merged
merged 2 commits into from

2 participants

@torrancew
Owner

Update to #23 to fix a failing test.

@torrancew torrancew merged commit 81000dc into develop
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Mar 8, 2014
  1. @aureq

    added 'allowdupe' to support users sharing same uid

    aureq authored committed
  2. Fix tests for allowdupe

    authored
This page is out of date. Refresh to see the latest.
Showing with 10 additions and 1 deletion.
  1. +7 −1 manifests/init.pp
  2. +3 −0  spec/defines/account_spec.rb
View
8 manifests/init.pp
@@ -75,6 +75,11 @@
# Defaults to 'users'
# WARNING: Has no effect if used with $create_group = true
#
+# [*allowdupe*]
+# Whether to allow duplicate UIDs.
+# Defaults to false.
+# Valid values are true, false, yes, no.
+#
# === Examples
#
# account { 'sysadmin':
@@ -95,7 +100,7 @@
$manage_home = true, $home_dir = undef, $home_dir_perms = '0750',
$create_group = true, $system = false, $uid = undef, $ssh_key = undef,
$ssh_key_type = 'ssh-rsa', $groups = [], $ensure = present,
- $comment= "${title} Puppet-managed User", $gid = 'users'
+ $comment= "${title} Puppet-managed User", $gid = 'users', $allowdupe = false
) {
if $home_dir == undef {
@@ -173,6 +178,7 @@
home => $home_dir_real,
managehome => $manage_home,
system => $system,
+ allowdupe => $allowdupe,
}
file {
View
3  spec/defines/account_spec.rb
@@ -26,6 +26,7 @@
'home' => "/home/#{title}",
'managehome' => true,
'system' => false,
+ 'allowdupe' => false,
'before' => "File[#{title}_home]",
})
end
@@ -62,6 +63,7 @@
:home_dir_perms => '0700',
:system => true,
:uid => 777,
+ :allowdupe => true,
:groups => [ 'sudo', 'users' ],
}}
@@ -83,6 +85,7 @@
'home' => params[:home_dir],
'manage_home' => params[:manage_home] == false ? nil : true,
'system' => params[:system],
+ 'allowdupe' => params[:allowdupe],
})
end
Something went wrong with that request. Please try again.