Skip to content
This repository was archived by the owner on Nov 8, 2021. It is now read-only.

Commit 9ea9c41

Browse files
mvanbaakmichaelwittig
authored andcommitted
Add the user to the supplementary group(s), without deleting the user from other groups an admin added this user to. Fixes #56 (#57)
1 parent 0e1a6d1 commit 9ea9c41

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

import_users.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ function create_or_update_local_user() {
135135
id "${username}" >/dev/null 2>&1 \
136136
|| ${USERADD_PROGRAM} ${USERADD_ARGS} "${username}" \
137137
&& /bin/chown -R "${username}:${username}" "$(eval echo ~$username)"
138-
/usr/sbin/usermod -G "${localusergroups}" "${username}"
138+
/usr/sbin/usermod -a -G "${localusergroups}" "${username}"
139139

140140
# Should we add this user to sudo ?
141141
if [[ ! -z "${SUDOERSGROUP}" ]]

0 commit comments

Comments
 (0)