From e655deb201816a313bdad7c444eb9a05e0b47af6 Mon Sep 17 00:00:00 2001 From: anmol26s Date: Tue, 24 Jul 2018 01:02:06 +0530 Subject: [PATCH] Add db migrate in upgrade script --- scripts/upgrade | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/scripts/upgrade b/scripts/upgrade index 908a41b..039b077 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -116,6 +116,13 @@ ynh_replace_string "__DBNAME__" "$db_name" "$final_path/config.production.js ynh_replace_string "__DBPWD__" "$db_pwd" "$final_path/config.production.json" ynh_replace_string "__PORT__" "$port" "$final_path/config.production.json" +# Migrate tables in database +( + cd "$final_path" +NODE_ENV=production knex-migrator init + +) + #================================================= # NGINX CONFIGURATION