Update install-ubuntu-dc.sh
This commit is contained in:
parent
2502e68bda
commit
c930b5cca3
@ -17,15 +17,14 @@ if ip r | grep -iq 'DHCP'; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
#: <<'END_COMMENT' END_COMMENT
|
#: <<'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 hostname:" -i "dc1" DCHOST
|
||||||
read -e -p "Enter realm:" -i "myspace.local" DCREALM
|
read -e -p "Enter realm:" -i "myspace.local" DCREALM
|
||||||
read -e -p "Enter domain:" -i "myspace" DCDOMAIN
|
read -e -p "Enter domain:" -i "myspace" DCDOMAIN
|
||||||
|
|
||||||
rm install.log /dev/null 2>&1
|
rm install.log /dev/null 2>&1
|
||||||
|
|
||||||
{
|
{
|
||||||
hostnamectl set-hostname $DCHOST &&
|
hostnamectl set-hostname $DCHOST &&
|
||||||
# timedatectl list-timezones | grep -i europe &&
|
# timedatectl list-timezones | grep -i europe &&
|
||||||
@ -35,7 +34,6 @@ rm install.log /dev/null 2>&1
|
|||||||
|
|
||||||
cat << EOF
|
cat << EOF
|
||||||
|
|
||||||
Use these settings:
|
|
||||||
------------------------------------------------------------
|
------------------------------------------------------------
|
||||||
Default Kerberos version 5 realm: ${DCREALM^^}
|
Default Kerberos version 5 realm: ${DCREALM^^}
|
||||||
Kerberos servers for your realm: $DCHOST.${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
|
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
|
} 2>>install.log
|
||||||
|
|
||||||
touch /var/lib/samba/sysvol/myspace.local/scripts/logon.cmd
|
touch /var/lib/samba/sysvol/${DCREALM,,}/scripts/logon.cmd
|
||||||
chmod 770 /var/lib/samba/sysvol/myspace.local/scripts/logon.cmd
|
chmod 770 /var/lib/samba/sysvol/${DCREALM,,}/scripts/logon.cmd
|
||||||
|
|
||||||
echo 'Installation complete'
|
echo 'Installation complete'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user