We declare all our users as virtual resources. E.g.:
@user { 'belmin':
uid => 2001
comment => 'Belmin Fernandez',
groups => ['sysadmins'],
}
Sometimes we temporarily realize
a user for a node:
node web1 {
realize User['belmin']
(...)
}
I am investigating ways to ensure that users that are not realized in the node do not exist on that server. The first way that comes to mind is doing this when the temporary realize
is removed:
node web1 {
User <| title == 'belmin' |> {
ensure => absent,
}
}
However, that could easily be accidentally omitted by someone when making the removal of the temporary realize
. Any other more elegant suggestions?