Update ADconnection.sh

This commit is contained in:
PierreGode 2018-08-13 14:59:46 +02:00 committed by GitHub
parent 5dbac2e615
commit 601b795a23
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -941,6 +941,10 @@ echo ""
echo "please type Domain admin"
read -r ADMIN
sudo realm join -v -U $ADMIN $DOMAIN --install=/
if [ $? -ne 0 ]; then
echo "AD join failed.please check that computer object is already created and test again"
exit 1
fi
sudo systemctl start sssd
echo "session required pam_mkhomedir.so skel=/etc/skel/ umask=0022" | sudo tee -a /etc/pam.d/common-session
sudo echo "pi ALL=(ALL) NOPASSWD:ALL" | sudo tee -a /etc/sudoers.d/sudoers