mirror of
https://github.com/PierreGode/Linux-Active-Directory-join-script.git
synced 2025-12-21 16:50:13 +01:00
Update ADconnection.sh
This commit is contained in:
parent
382049a213
commit
5a96b32f7f
@ -98,20 +98,23 @@ sudo echo "%DOMAIN\ admins ALL=(ALL) NOPASSWD:ALL" | sudo tee -a /etc/sudoers.d/
|
|||||||
#sudo realm permit --groups "$myhost""sudoers"
|
#sudo realm permit --groups "$myhost""sudoers"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
[Nn]* ) sudo echo "administrator ALL=(ALL:ALL) ALL" | sudo tee -a /etc/sudoers.d/sudoers
|
[Nn]* )
|
||||||
|
sudo echo "administrator ALL=(ALL:ALL) ALL" | sudo tee -a /etc/sudoers.d/sudoers
|
||||||
sudo echo "%$myhost""sudoers ALL=(ALL:ALL) ALL" | sudo tee -a /etc/sudoers.d/sudoers
|
sudo echo "%$myhost""sudoers ALL=(ALL:ALL) ALL" | sudo tee -a /etc/sudoers.d/sudoers
|
||||||
sudo echo "%DOMAIN\ admins ALL=(ALL:ALL) ALL" | sudo tee -a /etc/sudoers.d/domain_admins
|
sudo echo "%DOMAIN\ admins ALL=(ALL:ALL) ALL" | sudo tee -a /etc/sudoers.d/domain_admins
|
||||||
#sudo realm permit --groups "$myhost""sudoers"
|
#sudo realm permit --groups "$myhost""sudoers"
|
||||||
;;
|
;;
|
||||||
* ) echo "Please answer yes or no.";;
|
* ) echo "Please answer yes or no.";;
|
||||||
esac
|
esac
|
||||||
fi;;
|
fi
|
||||||
|
;;
|
||||||
[Nn]* ) echo "Disabled sudo rights for users on this machine"
|
[Nn]* ) echo "Disabled sudo rights for users on this machine"
|
||||||
echo ""
|
echo ""
|
||||||
echo ""
|
echo ""
|
||||||
states=$( echo 12 );;
|
states=$( echo 12 );;
|
||||||
* ) echo 'Please answer yes or no.';;
|
* ) echo "Please answer yes or no."
|
||||||
esac
|
;;
|
||||||
|
esac
|
||||||
homedir=$( cat /etc/pam.d/common-session | grep homedir | grep 0022 | cut -d '=' -f3 )
|
homedir=$( cat /etc/pam.d/common-session | grep homedir | grep 0022 | cut -d '=' -f3 )
|
||||||
if [ $homedir = 0022 ]
|
if [ $homedir = 0022 ]
|
||||||
then
|
then
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user