CFG_WEBSERVER=$(whiptail --title"Web server"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Please select Web server type" 10 50 2 "Nginx""(default)" ON "Apache""" OFF 3>&1 1>&2 2>&3)
MMLISTOWNER=$(whiptail --title"Mailman Site List Owner"--backtitle"$WT_BACKTITLE"--inputbox"Please specify the Mailman site list owner"--nocancel 10 60 "$USER" 3>&1 1>&2 2>&3)
done
while[[!"$MMADMINEMAIL"=~ $RE]]
do
MMADMINEMAIL=$(whiptail --title"Mailman Admin e-mail"--backtitle"$WT_BACKTITLE"--inputbox"Please specify the Mailman site list owner"--nocancel 10 60 "mailman@$CFG_HOSTNAME_DOMAIN" 3>&1 1>&2 2>&3)
done
echo-n-e"$IDENTATION_LVL_2${BBlack}Retrieve Mailman site list password${NC}: "
MMLISTPASS=$(whiptail --title"Mailman Site List Password"--backtitle"$WT_BACKTITLE"--inputbox\
"Please specify a Mailman Site List Password (leave empty for autogenerate)"--nocancel 10 60 3>&1 1>&2 2>&3)
CFG_SQLSERVER=$(whiptail --title"SQL Server"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Please select SQL Server type"$WT_HEIGHT$WT_WIDTH 2 "MariaDB""(default)" ON "MySQL""" OFF 3>&1 1>&2 2>&3)
CFG_WEBSERVER=$(whiptail --title"Web server"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Please select Web server type"$WT_HEIGHT$WT_WIDTH 2 "Nginx""(default)" ON "Apache""" OFF 3>&1 1>&2 2>&3)
CFG_FTP=$(whiptail --title"FTP Server"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Install and configure FTP SERVER?"$WT_HEIGHT$WT_WIDTH 4 "onlyFTP""Yes, only with FTP" OFF "onlyTLS""Yes, only with TLS" ON "FTPandTLS""Yes, with FTP and TLS" OFF "none""No, don't install it" OFF 3>&1 1>&2 2>&3)
do
done
CFG_ANTISPAM=$(whiptail --title"Spam detection"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Please select the spam detection software" 10 60 2 "rspamd""(default)" ON "amavisd""(Amavisd+SpamAssassin)" OFF 3>&1 1>&2 2>&3)
done
echo-n-e"$IDENTATION_LVL_1${BBlack}Install and Configure FTP Server${NC}: ${green}$CFG_FTP${NC} "
"Choose PHP Version do you want to install" 20 85 12 \
CFG_MTA=$(whiptail --title"Mail Server"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Select mailserver type"$WT_HEIGHT$WT_WIDTH 3 "None""" OFF "Dovecot""(default)" ON "Courier""" OFF 3>&1 1>&2 2>&3)
CFG_WEBMAIL=$(whiptail --title"Webmail client"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Select which Web Mail client you want"$WT_HEIGHT$WT_WIDTH 6 "Roundcube""(default)" OFF "Roundcube-latest""latest available" ON "RainLoop""" OFF "SOGo""" OFF "Squirrelmail""" OFF "None""No Web Mail Client" OFF 3>&1 1>&2 2>&3)
if(whiptail --title"Mailman"--backtitle"$WT_BACKTITLE"--yesno"Would you like to install Mailman?"$WT_HEIGHT$WT_WIDTH);then
CFG_MAILMAN=yes
echo-n-e"$IDENTATION_LVL_2${BBlack}Retrieve Mailman site password${NC}: "
MMSITEPASS=$(whiptail --title"Mailman Site Password"--backtitle"$WT_BACKTITLE"--inputbox"Please specify a Mailman Site Password (leave empty for autogenerate)"--nocancel$WT_HEIGHT$WT_WIDTH 3>&1 1>&2 2>&3)
MMLISTOWNER=$(whiptail --title"Mailman Site List Owner"--backtitle"$WT_BACKTITLE"--inputbox"Please specify the Mailman site list owner"--nocancel$WT_HEIGHT$WT_WIDTH"$USER" 3>&1 1>&2 2>&3)
done
while[[!"$MMADMINEMAIL"=~ $RE]];do
MMADMINEMAIL=$(whiptail --title"Mailman Admin e-mail"--backtitle"$WT_BACKTITLE"--inputbox"Please specify the Mailman site list owner"--nocancel$WT_HEIGHT$WT_WIDTH"mailman@$CFG_HOSTNAME_DOMAIN" 3>&1 1>&2 2>&3)
done
echo-n-e"$IDENTATION_LVL_2${BBlack}Retrieve Mailman site list password${NC}: "
MMLISTPASS=$(whiptail --title"Mailman Site List Password"--backtitle"$WT_BACKTITLE"--inputbox"Please specify a Mailman Site List Password (leave empty for autogenerate)"--nocancel$WT_HEIGHT$WT_WIDTH 3>&1 1>&2 2>&3)
CFG_PHPMYADMIN=$(whiptail --title"Install phpMyAdmin"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Do you want to install phpMyAdmin?"$WT_HEIGHT$WT_WIDTH 2 "Yes""(default)" ON "No""" OFF 3>&1 1>&2 2>&3)
CFG_PHPMYADMIN_VERSION=$(whiptail --title"phpMyAdmin Version"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"What version of phpMyAdmin do you want to install?"$WT_HEIGHT$WT_WIDTH 4 "Default""Current OS Version" OFF "Buster""From buster backports - newer" OFF "Bullseye""From bullseye backports - newer" OFF "Latest-stable""from phpMyAdmin.net" ON 3>&1 1>&2 2>&3)
"What version of phpMyAdmin do you want to install?" 15 75 4 \
while[[!"$CFG_METRONOME"=~ $RE]];do
"Default""Current OS Version" OFF \
CFG_METRONOME=$(whiptail --title"Metronome IM"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Do you want to install Metronome XMPP Chat server?"$WT_HEIGHT$WT_WIDTH 2 "No""(default)" ON "Yes""" OFF 3>&1 1>&2 2>&3)
"Buster""From buster backports - newer" OFF \
done
"Bullseye""From bullseye backports - newer" OFF \
"Latest-stable""from phpMyAdmin.net" ON 3>&1 1>&2 2>&3)
if(whiptail --title"Quota"--backtitle"$WT_BACKTITLE"--yesno"Setup user quota?"$WT_HEIGHT$WT_WIDTH);then
#echo -n -e "$IDENTATION_LVL_1 ${BBlack}Install DNS server (bind9)${NC}: ${green}$CFG_JKIT${NC} "
#if (whiptail --title "DNS (bind9)" --backtitle "$WT_BACKTITLE" --yesno "Would you like to install DNS server (bind9)?" --defaultno 10 60); then
#echo
# CFG_BIND=true
#else
#while [ "x$CFG_JOOMLA" == "x" ]
# CFG_BIND=false
# CFG_SETUP_NS=false
#fi
echo-n-e"$IDENTATION_LVL_1${BBlack}Install DNS server (bind9)${NC}: ${green}$CFG_JKIT${NC} "
echo
if(whiptail --title"WebStats"--backtitle"$WT_BACKTITLE"--yesno"Would you like to install WebStats?" 10 60);then
CFG_WEBSTATS=true
else
CFG_WEBSTATS=false
fi
echo-n-e"$IDENTATION_LVL_1${BBlack}Install DNS server (bind9)${NC}: ${green}$CFG_JKIT${NC} "
echo
#while [ "x$CFG_JOOMLA" == "x" ]
#do
#do
# CFG_JOOMLA=$(whiptail --title "Install CMS" --backtitle "$WT_BACKTITLE" --nocancel --radiolist "Select the default CMS" 10 50 2 "joomla" "(default)" ON "drupal" "" OFF 3>&1 1>&2 2>&3)
# CFG_JOOMLA=$(whiptail --title "Install CMS" --backtitle "$WT_BACKTITLE" --nocancel --radiolist "Select the default CMS" 10 50 2 "joomla" "(default)" ON "drupal" "" OFF 3>&1 1>&2 2>&3)
#done
#done
while["x$CFG_GITLABINSTALL"=="x"]
do
CFG_GITLABINSTALL=$(whiptail --title"Install Gitlab Server"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Do you want to install Gitlab Server?" 10 60 2 "yes""(default)" ON "no""" OFF 3>&1 1>&2 2>&3)
CFG_GITLABINSTALL=$(whiptail --title"Install Gitlab Server"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Do you want to install Gitlab Server?"$WT_HEIGHT$WT_WIDTH 2 "yes""(default)" ON "no""" OFF 3>&1 1>&2 2>&3)
CFG_CLOUDINSTALL=$(whiptail --title"Install Cloud Server"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Do you want to install a Cloud Server?" 10 60 2 "yes""(default)" ON "no""" OFF 3>&1 1>&2 2>&3)
fi
done
fi
if["$CFG_CLOUDINSTALL"=="yes"];then
while["x$CFG_CLOUDTYPE"=="x"]
do
CFG_CLOUDTYPE=$(whiptail --title"Select Cloud Server Type"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Which cloud server would you like to install?" 10 60 2 "nextcloud""Nextcloud Server" ON "seafile""Seafile Server" OFF 3>&1 1>&2 2>&3)
done
if["$CFG_CLOUDTYPE"=="nextcloud"];then
while["x$CFG_CLOUDUPGRADE"=="x"]
do
CFG_CLOUDUPGRADE=$(whiptail --title"Install Or Upgrade Nextcloud Server"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Do you want to upgrade Owncloud to Nextcloud Server or Fresh install?" 10 60 2 "yes""(Upgrade)" OFF "no""(Fresh install)" ON 3>&1 1>&2 2>&3)
done
fi
if["$CFG_CLOUDTYPE"=="seafile"];then
while["x$CFG_SEAFILEVERSION"=="x"]
do
CFG_SEAFILEVERSION=$(whiptail --title"Seafile Version"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Which Seafile version would you like to install?" 10 60 2 "pro""Seafile Pro" OFF "community""Seafile Community Edition" ON 3>&1 1>&2 2>&3)
done
fi
while["x$CFG_CLOUDDBTYPE"=="x"]
do
CFG_CLOUDDBTYPE=$(whiptail --title"$CFG_CLOUDTYPE Database Type"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Select database type for $CFG_CLOUDTYPE:" 10 60 2 "mysql""(default)" ON "sqlite""" OFF 3>&1 1>&2 2>&3)
done
while[[!"$CFG_CLOUDDBHOST"=~ $RE]]
do
CFG_CLOUDDBHOST=$(whiptail --title"$CFG_CLOUDTYPE DB host"--backtitle"$WT_BACKTITLE"--inputbox"$CFG_CLOUDTYPE database host - (default localhost) or (ext. host)"--nocancel 10 60 "localhost" 3>&1 1>&2 2>&3)
done
fi
echo-n-e"$IDENTATION_LVL_1${BBlack}Install cloud server ${NC}: ${green}$CFG_CLOUDINSTALL${NC} "
while["x$CFG_CLOUDINSTALL"=="x"];do
echo
CFG_CLOUDINSTALL=$(whiptail --title"Install Cloud Server"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Do you want to install a Cloud Server?"$WT_HEIGHT$WT_WIDTH 2 "yes""(default)" ON "no""" OFF 3>&1 1>&2 2>&3)
CFG_CLOUDTYPE=$(whiptail --title"Select Cloud Server Type"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Which cloud server would you like to install?"$WT_HEIGHT$WT_WIDTH 2 "nextcloud""Nextcloud Server" ON "seafile""Seafile Server" OFF 3>&1 1>&2 2>&3)
CFG_CLOUDUPGRADE=$(whiptail --title"Install Or Upgrade Nextcloud Server"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Do you want to upgrade Owncloud to Nextcloud Server or Fresh install?"$WT_HEIGHT$WT_WIDTH 2 "yes""(Upgrade)" OFF "no""(Fresh install)" ON 3>&1 1>&2 2>&3)
"Would you like full unattended setup of expert mode for ISPConfig?" 10 60 2 \
done
"standard""Yes (default)" ON \
fi
"expert""No, i want to configure" OFF 3>&1 1>&2 2>&3)
CFG_SEAFILEVERSION=$(whiptail --title"Seafile Version"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Which Seafile version would you like to install?"$WT_HEIGHT$WT_WIDTH 2 "pro""Seafile Pro" OFF "community""Seafile Community Edition" ON 3>&1 1>&2 2>&3)
"Please specify a ISPConfig Port (leave empty for use 8888 port)"--nocancel 10 60 3>&1 1>&2 2>&3)
CFG_CLOUDDBTYPE=$(whiptail --title"$CFG_CLOUDTYPE Database Type"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Select database type for $CFG_CLOUDTYPE:"$WT_HEIGHT$WT_WIDTH 2 "mysql""(default)" ON "sqlite""" OFF 3>&1 1>&2 2>&3)
done
if[[-z$CFG_ISPONCFIG_PORT]];then
while[[!"$CFG_CLOUDDBHOST"=~ $RE]];do
CFG_ISPONCFIG_PORT=8888
CFG_CLOUDDBHOST=$(whiptail --title"$CFG_CLOUDTYPE DB host"--backtitle"$WT_BACKTITLE"--inputbox"$CFG_CLOUDTYPE database host - (default localhost) or (ext. host)"--nocancel$WT_HEIGHT$WT_WIDTH"localhost" 3>&1 1>&2 2>&3)
"Please specify a ISPConfig Apps Port (leave empty for use 8083 port)"--nocancel 10 60 3>&1 1>&2 2>&3)
echo
if[[-z$CFG_ISPONCFIG_APPS_PORT]];then
while[[!"$CFG_ISPC"=~ $RE]];do
CFG_ISPONCFIG_APPS_PORT=8083
CFG_ISPC=$(whiptail --title"ISPConfig Setup"--backtitle"$WT_BACKTITLE"--nocancel--radiolist"Would you like full unattended setup of expert mode for ISPConfig?"$WT_HEIGHT$WT_WIDTH 2 "standard""Yes (default)" ON "expert""No, I want to configure" OFF 3>&1 1>&2 2>&3)
CFG_ISPONCFIG_PORT=$(whiptail --title"ISPConfig"--backtitle"$WT_BACKTITLE"--inputbox"Please specify an ISPConfig Port (leave empty for use 8888 port)"--nocancel$WT_HEIGHT$WT_WIDTH 3>&1 1>&2 2>&3)
CFG_ISPONCFIG_APPS_PORT=$(whiptail --title"ISPConfig"--backtitle"$WT_BACKTITLE"--inputbox"Please specify an ISPConfig Apps Port (leave empty for use 8083 port)"--nocancel$WT_HEIGHT$WT_WIDTH 3>&1 1>&2 2>&3)
echo-n-e"$IDENTATION_LVL_2${BBlack}Retrieve ISPConfig DB password${NC}: "
CFG_ISPCONFIG_DB_PASS=$(whiptail --title"ISPConfig DB Password"--backtitle"$WT_BACKTITLE"--inputbox"Please specify an ISPConfig DB Password (leave empty for autogenerate)"--nocancel$WT_HEIGHT$WT_WIDTH 3>&1 1>&2 2>&3)
echo-n-e"$IDENTATION_LVL_2${BBlack}Retrieve ISPConfig DB password${NC}: "
if[[-z$CFG_ISPONCFIG_ADMIN_PASS]];then
CFG_ISPCONFIG_DB_PASS=$(whiptail --title"ISPConfig DB Password"--backtitle"$WT_BACKTITLE"--inputbox\
CFG_ISPCONFIG_DB_PASS_AUTO=true
"Please specify a ISPConfig DB Password (leave empty for autogenerate)"--nocancel 10 60 3>&1 1>&2 2>&3)
SSL_STATE=$(whiptail --title"SSL State or Province Name"--backtitle"$WT_BACKTITLE"--inputbox"SSL Configuration - STATE or Province Name (full name - ex. Hungary)"--nocancel$WT_HEIGHT$WT_WIDTH"Hungary" 3>&1 1>&2 2>&3)
SSL_STATE=$(whiptail --title"SSL State or Province Name"--backtitle"$WT_BACKTITLE"--inputbox"SSL Configuration - STATE or Province Name (full name - ex. Hungary)"--nocancel 10 60 "Hungary" 3>&1 1>&2 2>&3)
echo-n-e"$IDENTATION_LVL_1 Installing dbconfig-common and fixing RoundCube... "
echo-n-e"$IDENTATION_LVL_1 Installing dbconfig-common and fixing RoundCube... "
package_install dbconfig-common dbconfig-mysql
apt_install dbconfig-common dbconfig-mysql
#There is currently a problem with the Debian dbconfig-common system which prevents the installation of RoundCube later, fix it by running this command:
#There is currently a problem with the Debian dbconfig-common system which prevents the installation of RoundCube later, fix it by running this command: