Is it possible to add an existing user to a group with puppet 2.7.18?
We have two modules, each one defines one class :
- module "user" creates all users, including user foo and user bar.
- module "subversion" deals with various conf files and creates group svn.
We would like to add user foo to group svn inside module "subversion".
I've tried the membership parameter as described in the existing feature request:
group {
"svn":
ensure => present,
gid => xxxxx;
}
user {
"foo":
group => ["svn"],
membership => minimum;
}
But I get the following error :
err: Could not retrieve catalog from remote server: Error 400 on SERVER: Duplicate declaration: User[foo] is already declared in file /pathto/modules/subversion/manifests/init.pp at line xx; cannot redeclare at /pathto/modules/users/manifests/init.pp:xxx on node myserver.example.com
Is this feature is already implemented? If not, is there a good workaround?