From e301510cfe12ea8d9b68c49773a9a0f821b5d61f Mon Sep 17 00:00:00 2001 From: PierreGoude Date: Mon, 19 Mar 2018 14:11:44 +0100 Subject: [PATCH] Update ADconnection.sh --- ADconnection.sh | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/ADconnection.sh b/ADconnection.sh index cb86546..6f8ccef 100644 --- a/ADconnection.sh +++ b/ADconnection.sh @@ -154,29 +154,29 @@ else # esac sudo realm join --verbose --user=$ADMIN $DOMAIN else - if [ "$var" -eq "17" ] + if [ "$var" -eq "17" ] || [ "$var" -eq "18" ] then echo "${INTRO_TEXT}"Detecting Ubuntu $var"${END}" sleep 1 clear - read -p "Do you wish to select an OU? (Default is CN=Computers,DC=domain,DC=com) (y/n)?" yn - case $yn in - [Yy]* ) echo "${INTRO_TEXT}"Please type OU"${END}" - read -r OU -MyOU=$(echo $OU | cut -d '=' -f1 | awk '{print toupper($0)}') -if [ "$MyOU" = OU ] -then -echo "Setting OU: $OU" -sudo realm join --user=ADMIN --computer-ou=$OU DOMAIN -else -echo "Something went wrong. please use this format ( OU=Computers,DC=domain,DC=com )" -exit -fi;; - - [Nn]* ) echo "";; - * ) echo 'Please answer yes or no.';; - esac - sudo realm join --verbose --user=$ADMIN $DOMAIN --install=/ +# read -p "Do you wish to select an OU? (Default is CN=Computers,DC=domain,DC=com) (y/n)?" yn +# case $yn in +# [Yy]* ) echo "${INTRO_TEXT}"Please type OU"${END}" +# read -r OU +#MyOU=$(echo $OU | cut -d '=' -f1 | awk '{print toupper($0)}') +#if [ "$MyOU" = OU ] +#then +#echo "Setting OU: $OU" +#sudo realm join --user=ADMIN --computer-ou=$OU DOMAIN +#else +#echo "Something went wrong. please use this format ( OU=Computers,DC=domain,DC=com )" +#exit +#fi;; +# +# [Nn]* ) echo "";; +# * ) echo 'Please answer yes or no.';; +# esac + sudo realm join --verbose --user=$ADMIN $DOMAIN --install=/ else clear sudo echo "${RED_TEXT}"I am having issuers to detect your Ubuntu version"${INTRO_TEXT}"