From c930b5cca3dd915937e1573419944e5716862824 Mon Sep 17 00:00:00 2001 From: Johan Date: Tue, 26 Jul 2022 21:54:40 +0200 Subject: [PATCH] Update install-ubuntu-dc.sh --- BashScripts/install-ubuntu-dc.sh | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/BashScripts/install-ubuntu-dc.sh b/BashScripts/install-ubuntu-dc.sh index bb8eaff..dd12778 100644 --- a/BashScripts/install-ubuntu-dc.sh +++ b/BashScripts/install-ubuntu-dc.sh @@ -17,15 +17,14 @@ if ip r | grep -iq 'DHCP'; then fi #: <<'END_COMMENT' END_COMMENT +cat << EOF +Before you continue, make sure your system is updated by running "apt update && apt upgrade" -# apt update - +EOF read -e -p "Enter hostname:" -i "dc1" DCHOST read -e -p "Enter realm:" -i "myspace.local" DCREALM read -e -p "Enter domain:" -i "myspace" DCDOMAIN - rm install.log /dev/null 2>&1 - { hostnamectl set-hostname $DCHOST && # timedatectl list-timezones | grep -i europe && @@ -35,7 +34,6 @@ rm install.log /dev/null 2>&1 cat << EOF -Use these settings: ------------------------------------------------------------ Default Kerberos version 5 realm: ${DCREALM^^} Kerberos servers for your realm: $DCHOST.${DCREALM,,} @@ -105,7 +103,7 @@ fi sed -i '/pam_unix.so/c\password [success=1 default=ignore] pam_unix.so minlen=0 sha512' /etc/pam.d/common-password } 2>>install.log -touch /var/lib/samba/sysvol/myspace.local/scripts/logon.cmd -chmod 770 /var/lib/samba/sysvol/myspace.local/scripts/logon.cmd +touch /var/lib/samba/sysvol/${DCREALM,,}/scripts/logon.cmd +chmod 770 /var/lib/samba/sysvol/${DCREALM,,}/scripts/logon.cmd echo 'Installation complete'