1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/castopod_ynh.git synced 2024-09-03 18:16:14 +02:00

Fix upgrade

This commit is contained in:
orhtej2 2023-10-23 22:19:06 +02:00
parent 43a9d95039
commit c7e9bf4238

View file

@ -72,13 +72,6 @@ ynh_add_config --template="../conf/cron" --destination="/etc/cron.d/$app"
chown root: "/etc/cron.d/$app" chown root: "/etc/cron.d/$app"
chmod 644 "/etc/cron.d/$app" chmod 644 "/etc/cron.d/$app"
#=================================================
# CONFIGURE CASTOPOD DATABASE
#=================================================
ynh_script_progression --message="Configuring Castopod database..." --weight=1
ynh_mysql_connect_as --user=$db_user --password=$db_pwd --database=$db_name < "../conf/v1.5.2.sql"
#================================================= #=================================================
# ADD CONFIGURE # ADD CONFIGURE
#================================================= #=================================================
@ -88,6 +81,15 @@ ynh_add_config --template="../conf/.env.example" --destination="$install_dir/.en
chmod 600 $install_dir/.env chmod 600 $install_dir/.env
chown $app:www-data "$install_dir/.env" chown $app:www-data "$install_dir/.env"
#=================================================
# CONFIGURE CASTOPOD DATABASE
#=================================================
ynh_script_progression --message="Configuring Castopod database..." --weight=1
pushd $install_dir
sudo -u $app php${phpversion} spark migrate --all
popd
#================================================= #=================================================
# END OF SCRIPT # END OF SCRIPT
#================================================= #=================================================