Check for database scheme at an earlier stage

This commit is contained in:
Bob Mottram 2018-02-18 12:45:44 +00:00
parent 9351ed6598
commit 3e9d2f0e09
1 changed files with 5 additions and 5 deletions

View File

@ -386,6 +386,11 @@ function install_hubzilla {
chown -R www-data:www-data $HUBZILLA_PATH
fi
if [ ! -f $HUBZILLA_PATH/install/schema_mysql.sql ]; then
echo $'No database schema found for hubzilla'
exit 252782
fi
HUBZILLA_ONION_HOSTNAME=
if [[ $ONION_ONLY != "no" ]]; then
HUBZILLA_ONION_HOSTNAME=$(add_onion_service hubzilla 80 ${HUBZILLA_ONION_PORT})
@ -578,11 +583,6 @@ function install_hubzilla {
function_check nginx_ensite
nginx_ensite $HUBZILLA_DOMAIN_NAME
# initialize the database
if [ ! -f $HUBZILLA_PATH/install/schema_mysql.sql ]; then
echo $'No database schema found for hubzilla'
exit 252782
fi
function_check initialise_database
initialise_database hubzilla $HUBZILLA_PATH/install/schema_mysql.sql