diff --git a/scripts/upgrade b/scripts/upgrade index 50b56fb..0d98727 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -133,9 +133,15 @@ ynh_script_progression --message="Upgrading the database..." pushd "$final_path" # Clear caches # https://github.com/invoiceninja/invoiceninja/issues/7397 - ynh_secure_remove --file=bootstrap/cache/* - ynh_secure_remove --file=storage/framework/cache/* - ynh_secure_remove --file=storage/framework/sessions/* + ynh_secure_remove --file=$final_path/bootstrap/cache/ + ynh_secure_remove --file=$final_path/storage/framework/cache/ + ynh_secure_remove --file=$final_path/storage/framework/sessions/ + + mkdir -p $final_path/bootstrap/cache/ $final_path/storage/framework/cache/ $final_path/storage/framework/sessions/ + + # clear cached stuff under /app/data/storage/framework (https://github.com/laravel/framework/issues/17377) + php$phpversion artisan view:clear + php$phpversion artisan cache:clear # Run the database migrations php$phpversion artisan migrate --force --no-interaction --verbose