diff --git a/debian/alternc.config b/debian/alternc.config index c1fce570..4b33c591 100644 --- a/debian/alternc.config +++ b/debian/alternc.config @@ -51,13 +51,17 @@ check_mysql() if [ "`mysql -u"$MYSQL_USER" -p"$MYSQL_PASSWORD" -h"$MYSQL_HOST" -Bse 'SELECT "OK";' 2>/dev/null`" = "OK" ]; then STATE=`expr $STATE + 1` else - db_input high alternc/remote_mysql_error || true + db_input high alternc/retry_remote_mysql || true if [ $? -eq 30 ]; then + db_input high alternc/remote_mysql_error || true + db_go || true exit 4 fi db_go - db_get alternc/remote_mysql_error || true + db_get alternc/retry_remote_mysql || true if [ "$RET" = "false" ]; then + db_input high alternc/remote_mysql_error || true + db_go || true exit 4 fi fi diff --git a/debian/alternc.templates b/debian/alternc.templates index a7cd8d04..49fa3317 100644 --- a/debian/alternc.templates +++ b/debian/alternc.templates @@ -241,7 +241,7 @@ _Description: Use a remote MySQL server? Please confirm you want to use a remote Mysql Server. If not, AlternC cannot be installed. -Template: alternc/remote_mysql_error +Template: alternc/retry_remote_mysql Type: boolean _Description: MySQL connection error. Try again? Remote connection to the MySQL server failed. @@ -254,3 +254,10 @@ _Description: Private IP detected, use it anyway? this is an expected situation, since the server might not be reachable from outside your network. +Template: alternc/remote_mysql_error +Type: error +_Description: Remote mysql: connection error + Connection to the remote MySQL server failed. + . + This is a fatal error and will cause the package installation + to fail.