Fix user::managed for earlier (<3.6) puppet agents

This commit is contained in:
Jerome Charaoui 2015-06-04 11:04:58 -04:00
parent 885f52f2d8
commit 7efadcb05d

View file

@ -78,9 +78,18 @@ define user::managed(
shell => $real_shell,
groups => $groups,
membership => $membership,
purge_ssh_keys => $purge_ssh_keys,
}
if $purge_ssh_keys {
if versioncmp($::puppetversion, '3.6') >= 0 {
User[$name] {
purge_ssh_keys => true
}
}
else {
notice("Parameter purge_ssh_keys is unsupported in your Puppet agent!")
}
}
if $managehome {
file{$real_homedir: }