diff --git a/scripts/upgrade b/scripts/upgrade index 63e5742..78e8f87 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -83,6 +83,18 @@ then chmod -R o-rwx "$install_dir" chown -R $app:www-data "$install_dir" chmod -R 775 $install_dir/store $install_dir/cache + + #================================================= + # ADDONS + #================================================= + ynh_script_progression --message="Installing addons..." + + pushd $install_dir + ynh_exec_as $app git config pull.rebase false + ynh_exec_as $app util/add_addon_repo https://codeberg.org/streams/streams-addons.git zaddons + cd /var/www/$app/extend/addon/zaddons + ynh_exec_as $app git config pull.rebase false + popd fi fi @@ -119,12 +131,15 @@ chown $app:$app "$install_dir/.htconfig.php" #================================================= # UPGRADE CRON JOB #================================================= -ynh_script_progression --message="Upgrading cron job..." --weight=1 +ynh_script_progression --message="Setuping cron job..." --weight=1 # Set up cron job -ynh_add_config --template="../conf/poller-cron" --destination="/etc/cron.d/$app" +ynh_add_config --template="../conf/cronjobs" --destination="/etc/cron.d/$app" chown root: "/etc/cron.d/$app" chmod 644 "/etc/cron.d/$app" +# Add daily update script +ynh_add_config --template="../conf/daily-update.sh" --destination="/home/yunohost.app/$app/daily-update.sh" +chown root: "/home/yunohost.app/$app/daily-update.sh" #================================================= # GENERIC FINALIZATION