mirror of
https://github.com/PierreGode/Linux-Active-Directory-join-script.git
synced 2025-12-21 16:50:13 +01:00
improved detecting fails and errors.
This commit is contained in:
parent
60063f372b
commit
50c80a2fe6
@ -1151,7 +1151,7 @@ read -r DOMAIN
|
|||||||
else
|
else
|
||||||
echo ""
|
echo ""
|
||||||
fi
|
fi
|
||||||
therealm=$( realm discover | grep -i realm-name | awk '{print $2}')
|
therealm=$( realm discover | grep -i configured | awk '{print $2}')
|
||||||
if [ "$therealm" = "no" ]
|
if [ "$therealm" = "no" ]
|
||||||
then
|
then
|
||||||
echo Realm configured?.. "${RED_TEXT}FAIL${END}"
|
echo Realm configured?.. "${RED_TEXT}FAIL${END}"
|
||||||
@ -1161,7 +1161,7 @@ fi
|
|||||||
if [ -f /etc/sudoers.d/admins ] < /dev/null > /dev/null 2>&1
|
if [ -f /etc/sudoers.d/admins ] < /dev/null > /dev/null 2>&1
|
||||||
then
|
then
|
||||||
echo Checking sudoers file.. "${INTRO_TEXT}OK${END}"
|
echo Checking sudoers file.. "${INTRO_TEXT}OK${END}"
|
||||||
grouPs=$(grep -i "$myhost" /etc/sudoers.d/admins | cut -d '%' -f2 | cut -d '=' -f1 | sed -e 's/\<ALL\>//g')
|
grouPs=$(grep -i "$myhost" /etc/sudoers.d/sudoers | cut -d '%' -f2 | cut -d '=' -f1 | sed -e 's/\<ALL\>//g')
|
||||||
if [ $grouPs = "$myhost""sudoers" ]
|
if [ $grouPs = "$myhost""sudoers" ]
|
||||||
then
|
then
|
||||||
echo Checking sudoers users.. "${INTRO_TEXT}OK${END}"
|
echo Checking sudoers users.. "${INTRO_TEXT}OK${END}"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user