From b993c64f6f5f47cd2383e1e917a6f45fcf6f90fe Mon Sep 17 00:00:00 2001 From: orhtej2 <2871798+orhtej2@users.noreply.github.com> Date: Sat, 28 Oct 2023 22:44:28 +0200 Subject: [PATCH] Fix install and upgrade behaviour. --- scripts/install | 9 --------- scripts/upgrade | 3 ++- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/scripts/install b/scripts/install index 5441e89..844bcc4 100755 --- a/scripts/install +++ b/scripts/install @@ -69,15 +69,6 @@ ynh_add_config --template=".env.example" --destination="$install_dir/.env" chmod 600 $install_dir/.env chown $app:www-data "$install_dir/.env" -#================================================= -# RUN MIGRATIONS -#================================================= -ynh_script_progression --message="Configuring $app database..." --weight=1 - -pushd $install_dir - ynh_exec_warn_less ynh_exec_as $app php${phpversion} spark migrate --all -popd - #================================================= # END OF SCRIPT #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index bb6cb7d..57015a2 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -85,7 +85,8 @@ chown $app:www-data "$install_dir/.env" ynh_script_progression --message="Configuring $app database..." --weight=1 pushd $install_dir - ynh_exec_warn_less ynh_exec_as $app php${phpversion} spark migrate --all + ynh_exec_warn_less ynh_exec_as $app php${phpversion} spark castopod:database-update + ynh_exec_warn_less ynh_exec_as $app php${phpversion} spark cache:clear popd #=================================================