From e5679165907289cc096d18e41d0585435f90668c Mon Sep 17 00:00:00 2001 From: PierreGoude Date: Fri, 10 Feb 2017 08:35:51 +0100 Subject: [PATCH] Update ADconnection.sh --- ADconnection.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/ADconnection.sh b/ADconnection.sh index 0a0c02b..a77754b 100644 --- a/ADconnection.sh +++ b/ADconnection.sh @@ -43,7 +43,16 @@ export HOSTNAME myhost=$( hostname ) sudo apt-get -qq install realmd adcli sssd -y sudo apt-get -qq install ntp -y +sudo dpkg -l | grep realmd clear +if [ $? = 0 ] +then +sudo echo "${INTRO_TEXT}"Pakages installed"${END}" +else +sudo echo "${RED_TEXT}"Installing pakages failed.. please check connectio and dpkg and try again."${INTRO_TEXT}" +exit +fi +sleep 1 DOMAIN=$(realm discover | grep -i realm.name | cut -d ':' -f2 | sed -e 's/^[[:space:]]*//') echo "${NUMBER}I searched for an available domain and found >>> $DOMAIN <<< ${END}" discovery=$(realm discover $DOMAIN | grep domain-name)