diff --git a/install_roundcube.sh b/install_roundcube.sh index e753520..d73ed7f 100755 --- a/install_roundcube.sh +++ b/install_roundcube.sh @@ -295,6 +295,10 @@ do echo -e "\n\t\033[33m\033[1mA version number is required!\033[m\n" fi done +# Hauptversionsnummer extrahieren (1.6 oder 1.7) +RC_MAIN_VERSION=$(echo "$ROUNDCUBE_VERSION" | cut -d. -f1-2) + + echo "" echo -e "\033[32m--\033[m" echo "" @@ -1095,18 +1099,27 @@ if [[ -h "${WEBSITE_BASEDIR}/htdocs" ]]; then else echo_skipped fi + +_failed=false echononl "\tCreate Symlink for DocumentRoot Directory 'htdocs'.." -if [[ ! -h "${WEBSITE_BASEDIR}/htdocs" ]]; then - ln -s roundcubemail-${ROUNDCUBE_VERSION} ${WEBSITE_BASEDIR}/htdocs > $log_file 2>&1 - if [[ $? -eq 0 ]]; then - echo_ok - else - echo_failed - error "$(cat $log_file)" +if [ "$RC_MAIN_VERSION" == "1.6" ]; then + ln -s "roundcubemail-${ROUNDCUBE_VERSION}" "${WEBSITE_BASEDIR}/htdocs" >> $log_file 2>&1 + if [[ $? -ne 0 ]]; then + _failed=true fi else - echo_skipped + ln -s "roundcubemail-${ROUNDCUBE_VERSION}/public_html/" "${WEBSITE_BASEDIR}/htdocs" >> $log_file 2>&1 + if [[ $? -ne 0 ]]; then + _failed=true + fi fi +if $_failed ; then + echo_failed + error "$(cat $log_file)" +else + echo_ok +fi + if $SKIN_LOGO_PRESENT ; then _failed=false @@ -1945,10 +1958,15 @@ else echo_skipped fi +if [ "$RC_MAIN_VERSION" == "1.6" ]; then + INSTALLER_URL="https://${WEBSITE_NAME}/installer" +else + INSTALLER_URL="https://${WEBSITE_NAME}/installer.php" +fi info "Now browse to the intaller site and continue installation.\n$(cat <