2017-02-13 22:51:20 +01:00
|
|
|
#!/bin/bash
|
|
|
|
|
2022-03-09 03:00:02 +01:00
|
|
|
#=================================================
|
|
|
|
# GENERIC START
|
|
|
|
#=================================================
|
|
|
|
# IMPORT GENERIC HELPERS
|
|
|
|
#=================================================
|
|
|
|
|
|
|
|
source _common.sh
|
2017-02-13 22:51:20 +01:00
|
|
|
source /usr/share/yunohost/helpers
|
2022-03-09 03:00:02 +01:00
|
|
|
|
|
|
|
#=================================================
|
|
|
|
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
|
|
|
#=================================================
|
2024-01-16 23:02:56 +01:00
|
|
|
ynh_script_progression --message="Upgrading source files..."
|
2022-03-09 03:00:02 +01:00
|
|
|
|
2024-01-16 23:02:56 +01:00
|
|
|
# Download, check integrity, uncompress and patch the source from app.src
|
|
|
|
ynh_setup_source --dest_dir="$install_dir" --full_replace=1 --keep="DATAS"
|
2017-02-13 22:51:20 +01:00
|
|
|
|
2024-01-16 22:52:20 +01:00
|
|
|
chmod 750 "$install_dir"
|
|
|
|
chmod -R o-rwx "$install_dir"
|
2024-01-16 23:02:56 +01:00
|
|
|
chown -R "$app:www-data" "$install_dir"
|
2022-03-09 03:00:02 +01:00
|
|
|
|
|
|
|
#=================================================
|
2024-01-16 23:02:56 +01:00
|
|
|
# REAPPLY SYSTEM CONFIGURATIONS
|
2022-03-09 03:00:02 +01:00
|
|
|
#=================================================
|
2024-01-16 23:02:56 +01:00
|
|
|
ynh_script_progression --message="Upgrading system configurations related to $app..." --weight=1
|
2022-03-09 03:00:02 +01:00
|
|
|
|
|
|
|
ynh_add_fpm_config
|
|
|
|
|
2024-01-16 23:02:56 +01:00
|
|
|
ynh_add_nginx_config
|
2022-03-09 03:00:02 +01:00
|
|
|
|
|
|
|
#=================================================
|
|
|
|
# END OF SCRIPT
|
|
|
|
#=================================================
|
|
|
|
|
|
|
|
ynh_script_progression --message="Upgrade of $app completed"
|