From 36f8fb5b103d88936a80e70a6370ad3c5fa776e1 Mon Sep 17 00:00:00 2001 From: Luke Murphy Date: Tue, 24 Sep 2019 12:08:24 +0200 Subject: [PATCH] Run the migrations as well --- scripts/install | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scripts/install b/scripts/install index 2e73a78..96d16bd 100755 --- a/scripts/install +++ b/scripts/install @@ -167,6 +167,14 @@ ynh_replace_string --match_string="__DB_NAME__" --replace_string="$app_web" --ta ynh_replace_string --match_string="__DB_USER__" --replace_string="$app_web" --target_file="/etc/mailman3/mailman-web.py" ynh_replace_string --match_string="__DB_PWD__" --replace_string="$db_pwd_app_web" --target_file="/etc/mailman3/mailman-web.py" +#================================================= +# RUN DATABASE MIGRATIONS +#================================================= + +ynh_script_progression --message="Running database migrations..." --weight=6 + +cd /usr/share/mailman3-web && python3 manage.py migrate || ynh_die --message="Mailman3 migrations failed!" + #================================================= # STORE THE CONFIG FILE CHECKSUM #=================================================