fixed adding user to group
This commit is contained in:
parent
01ee94db17
commit
ccf9d5046c
1 changed files with 12 additions and 12 deletions
|
@ -68,18 +68,18 @@ useradd -m -g users -s "/bin/zsh" "$user"
|
|||
printf "|> setting password for user '$user'...\n"
|
||||
echo -e "$password\n$password" | passwd "$user"
|
||||
|
||||
printf "|> adding user '$user' to group 'disk'...\n" && addgroup "$user" disk > /dev/null
|
||||
printf "|> adding user '$user' to group 'lp'...\n" && addgroup "$user" lp > /dev/null
|
||||
printf "|> adding user '$user' to group 'wheel'...\n" && addgroup "$user" wheel > /dev/null
|
||||
printf "|> adding user '$user' to group 'floppy'...\n" && addgroup "$user" floppy > /dev/null
|
||||
printf "|> adding user '$user' to group 'audio'...\n" && addgroup "$user" audio > /dev/null
|
||||
printf "|> adding user '$user' to group 'cdrom'...\n" && addgroup "$user" cdrom > /dev/null
|
||||
printf "|> adding user '$user' to group 'dialout'...\n" && addgroup "$user" dialout > /dev/null
|
||||
printf "|> adding user '$user' to group 'tape'...\n" && addgroup "$user" tape > /dev/null
|
||||
printf "|> adding user '$user' to group 'video'...\n" && addgroup "$user" video > /dev/null
|
||||
printf "|> adding user '$user' to group 'netdev'...\n" && addgroup "$user" netdev > /dev/null
|
||||
printf "|> adding user '$user' to group 'games'...\n" && addgroup "$user" games > /dev/null
|
||||
printf "|> adding user '$user' to group 'sudo'...\n" && addgroup "$user" sudo > /dev/null
|
||||
printf "|> adding user '$user' to group 'disk'...\n" && gpasswd -a "$user" disk > /dev/null
|
||||
printf "|> adding user '$user' to group 'lp'...\n" && gpasswd -a "$user" lp > /dev/null
|
||||
printf "|> adding user '$user' to group 'wheel'...\n" && gpasswd -a "$user" wheel > /dev/null
|
||||
printf "|> adding user '$user' to group 'floppy'...\n" && gpasswd -a "$user" floppy > /dev/null
|
||||
printf "|> adding user '$user' to group 'audio'...\n" && gpasswd -a "$user" audio > /dev/null
|
||||
printf "|> adding user '$user' to group 'cdrom'...\n" && gpasswd -a "$user" cdrom > /dev/null
|
||||
printf "|> adding user '$user' to group 'dialout'...\n" && gpasswd -a "$user" dialout > /dev/null
|
||||
printf "|> adding user '$user' to group 'tape'...\n" && gpasswd -a "$user" tape > /dev/null
|
||||
printf "|> adding user '$user' to group 'video'...\n" && gpasswd -a "$user" video > /dev/null
|
||||
printf "|> adding user '$user' to group 'netdev'...\n" && gpasswd -a "$user" netdev > /dev/null
|
||||
printf "|> adding user '$user' to group 'games'...\n" && gpasswd -a "$user" games > /dev/null
|
||||
printf "|> adding user '$user' to group 'sudo'...\n" && gpasswd -a "$user" sudo > /dev/null
|
||||
|
||||
printf "|> modifying sudoers...\n"
|
||||
sed -i "s/# %sudo ALL=(ALL) ALL/%sudo ALL=(ALL) ALL/" "/etc/sudoers"
|
||||
|
|
Loading…
Reference in a new issue