2015-02-26 23:40:40 +01:00
|
|
|
#!/bin/bash
|
|
|
|
|
2020-11-05 13:34:17 +01:00
|
|
|
#=================================================
|
|
|
|
# GENERIC START
|
|
|
|
#=================================================
|
|
|
|
# IMPORT GENERIC HELPERS
|
|
|
|
#=================================================
|
2015-02-26 23:40:40 +01:00
|
|
|
|
2020-11-05 13:34:17 +01:00
|
|
|
source _common.sh
|
|
|
|
source /usr/share/yunohost/helpers
|
2015-02-26 23:40:40 +01:00
|
|
|
|
2020-11-27 12:41:05 +01:00
|
|
|
#=================================================
|
2022-06-03 21:36:50 +02:00
|
|
|
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
2020-11-05 13:34:17 +01:00
|
|
|
#=================================================
|
2022-06-03 21:36:50 +02:00
|
|
|
ynh_script_progression --message="Upgrading source files..."
|
2020-11-05 13:34:17 +01:00
|
|
|
|
2023-10-02 19:37:44 +02:00
|
|
|
cp -a ../sources/* "$install_dir"
|
2021-05-15 16:33:18 +02:00
|
|
|
|
2023-10-02 19:37:44 +02:00
|
|
|
chmod 750 "$install_dir"
|
|
|
|
chmod -R o-rwx "$install_dir"
|
|
|
|
chown -R "$app:www-data" "$install_dir"
|
2020-11-05 13:34:17 +01:00
|
|
|
|
|
|
|
#=================================================
|
|
|
|
# NGINX CONFIGURATION
|
|
|
|
#=================================================
|
|
|
|
ynh_script_progression --message="Upgrading NGINX web server configuration..." --weight=2
|
|
|
|
|
|
|
|
ynh_add_nginx_config
|
|
|
|
|
2022-06-03 21:36:50 +02:00
|
|
|
#=================================================
|
|
|
|
# PHP-FPM CONFIGURATION
|
|
|
|
#=================================================
|
|
|
|
ynh_script_progression --message="Upgrading PHP-FPM configuration..."
|
|
|
|
|
|
|
|
ynh_add_fpm_config --usage=low --footprint=low
|
|
|
|
|
2020-11-05 13:34:17 +01:00
|
|
|
#=================================================
|
|
|
|
# END OF SCRIPT
|
|
|
|
#=================================================
|
|
|
|
|
2022-06-03 21:36:50 +02:00
|
|
|
ynh_script_progression --message="Upgrade of $app completed" --last
|