1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/transmission_ynh.git synced 2024-09-04 01:46:12 +02:00

Update upgrade

This commit is contained in:
Éric Gaspar 2023-09-29 13:41:25 +02:00
parent 47788b0527
commit 5aa7bbcaec

View file

@ -32,18 +32,6 @@ ynh_script_progression --message="Upgrading NGINX web server configuration..." -
# Create a dedicated NGINX config # Create a dedicated NGINX config
ynh_add_nginx_config ynh_add_nginx_config
#=================================================
# SPECIFIC UPGRADE
#=================================================
# CREATE DATA DIRECTORY
#=================================================
ynh_script_progression --message="Creating a data directory..." --weight=1
chmod -R 764 $data_dir
chmod -R 775 $data_dir/watched
chown -R debian-transmission:www-data "$data_dir"
chown -R debian-transmission: $data_dir/{progress,watched}
#================================================= #=================================================
# UPDATE A CONFIG FILE # UPDATE A CONFIG FILE
#================================================= #=================================================
@ -104,6 +92,16 @@ fi
ynh_replace_string "<div id=\"toolbar-inspector\" title=\"Toggle Inspector\"></div>$" "<div id=\"toolbar-inspector\" title=\"Toggle Inspector\"></div><div id=\"toolbar-separator\"></div><a href=\"../../downloads/\" id=\"toolbar-downloads\" title=\"Downloads\" target=\"_blank\"></a>" /usr/share/transmission/web/index.html ynh_replace_string "<div id=\"toolbar-inspector\" title=\"Toggle Inspector\"></div>$" "<div id=\"toolbar-inspector\" title=\"Toggle Inspector\"></div><div id=\"toolbar-separator\"></div><a href=\"../../downloads/\" id=\"toolbar-downloads\" title=\"Downloads\" target=\"_blank\"></a>" /usr/share/transmission/web/index.html
#=================================================
# SET DATA DIRECTORY PERMISSIONS
#=================================================
ynh_script_progression --message="Set data directory permissions..." --weight=1
chmod -R 764 $data_dir
chmod -R 775 $data_dir/watched
chown -R debian-transmission:www-data "$data_dir"
chown -R debian-transmission: $data_dir/{progress,watched}
#================================================= #=================================================
# GENERIC FINALIZATION # GENERIC FINALIZATION
#================================================= #=================================================