Browse Source

Added --all option for Web and Mail install and added dovecot package check

old-stable
gau1991 10 years ago
parent
commit
974148e57e
  1. 4
      bin/easyengine
  2. 14
      src/modules/stack/install/mail/ee_mod_install_dovecot.sh

4
bin/easyengine

@ -128,9 +128,9 @@ elif [ "$EE_FIRST" = "stack" ] || [ "$EE_FIRST" = "system" ]; then
ee_lib_echo "Successfully installed all packages"
ee_lib_echo "Create your first WordPress site powered by NGINX using:"
ee_lib_echo_info "ee site create example.com --wp"
fi
# EasyEngine mail server setup
elif [ "$EE_THIRD" = "--mail" ] || [ "$EE_THIRD" = "--all" ];then
if [ "$EE_THIRD" = "--mail" ] || [ "$EE_THIRD" = "--all" ];then
# Install Dovecot
ee_mod_install_dovecot

14
src/modules/stack/install/mail/ee_mod_install_dovecot.sh

@ -3,9 +3,23 @@
function ee_mod_install_dovecot()
{
# Install Dovecot
dpkg -l | grep nginx > /dev/null \
&& dpkg -l | grep php5-fpm > /dev/null \
&& dpkg -l | grep mysql > /dev/null \
&& dpkg -l | grep postfix > /dev/null
if [ $? -ne 0 ];then
ee_lib_error "Failed to find pre dependencies. Please install Nginx, PHP5, MySQL and Postfix using command ee stack install, exit status " 1
fi
dkpg -l | grep dovecot-core > /dev/null
if [$? -eq 0 ];then
ee_lib_error "Found installed mail server, Please remove it before installation, exit status=" 1
fi
ee_lib_echo "Installing Dovecot, please wait..."
debconf-set-selections <<< "dovecot-core dovecot-core/create-ssl-cert boolean yes"
debconf-set-selections <<< "dovecot-core dovecot-core/ssl-cert-name string $(hostname -f)"
$EE_APT_GET install dovecot-core dovecot-imapd dovecot-pop3d dovecot-lmtpd dovecot-mysql dovecot-sieve dovecot-managesieved \
|| ee_lib_error "Unable to install Dovecot, exit status = " $?
}

Loading…
Cancel
Save