Created
June 21, 2017 02:11
-
-
Save ailtonbsj/74c88ced6280b9cd82d3e099a947def9 to your computer and use it in GitHub Desktop.
Removendo “freeze” do LE5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Make sure only root can run our script | |
if [ "$(id -u)" != "0" ]; then | |
echo "This script must be run as root" | |
exit 1 | |
fi | |
awk -F':' '{ print $1}' /etc/passwd | grep aluno > usrs | |
cat usrs | while read line; do | |
userdel -r $line | |
done | |
sed -i 's/allow-guest=true/allow-guest=false/g' \ | |
/etc/lightdm/lightdm.conf | |
useradd -G professor -d /home/aluno Aluno | |
passwd -d Aluno | |
cp -R /home/professor /home/aluno | |
chown -R Aluno.professor /home/aluno | |
reboot |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment