mirror of
https://github.com/YunoHost-Apps/kavita_ynh.git
synced 2024-09-03 19:26:30 +02:00
0.7.2~ynh1
This commit is contained in:
parent
4b32b5ac04
commit
5e85c1a344
1 changed files with 35 additions and 2 deletions
|
@ -5,9 +5,18 @@
|
|||
#=================================================
|
||||
# IMPORT GENERIC HELPERS
|
||||
#=================================================
|
||||
|
||||
source _common.sh
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
#=================================================
|
||||
# STANDARD MODIFICATIONS
|
||||
#=================================================
|
||||
# STOP SYSTEMD SERVICE
|
||||
#=================================================
|
||||
ynh_script_progression --message="Stopping a systemd service..." --weight=1
|
||||
|
||||
ynh_systemd_action --service_name=$app --action=stop --log_path=systemd
|
||||
|
||||
#=================================================
|
||||
# MODIFY URL IN NGINX CONF
|
||||
#=================================================
|
||||
|
@ -15,8 +24,32 @@ ynh_script_progression --message="Updating NGINX web server configuration..." --
|
|||
|
||||
ynh_change_url_nginx_config
|
||||
|
||||
#=================================================
|
||||
# SPECIFIC MODIFICATIONS
|
||||
#=================================================
|
||||
# CONFIGURE Kavita
|
||||
#=================================================
|
||||
ynh_backup_if_checksum_is_different --file="$install_dir/config/appsettings.json"
|
||||
|
||||
domain=$new_domain
|
||||
url_path=${new_path#/}
|
||||
|
||||
ynh_add_config --template="../conf/appsettings.json.example" --destination="$install_dir/config/appsettings.json"
|
||||
|
||||
chmod 400 "$install_dir/config/appsettings.json"
|
||||
chown $app:$app "$install_dir/config/appsettings.json"
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALISATION
|
||||
#=================================================
|
||||
# START SYSTEMD SERVICE
|
||||
#=================================================
|
||||
ynh_script_progression --message="Starting a systemd service..." --weight=1
|
||||
|
||||
# Start a systemd service
|
||||
ynh_systemd_action --service_name=$app --action=start
|
||||
|
||||
#=================================================
|
||||
# END OF SCRIPT
|
||||
#=================================================
|
||||
|
||||
ynh_script_progression --message="Change of URL completed for $app" --last
|
||||
|
|
Loading…
Add table
Reference in a new issue