mirror of
https://github.com/YunoHost-Apps/syncthing_ynh.git
synced 2024-09-03 20:26:23 +02:00
Variables cleanup
This commit is contained in:
parent
31e154327c
commit
53ebb68abf
3 changed files with 11 additions and 6 deletions
|
@ -29,7 +29,6 @@ app=$YNH_APP_INSTANCE_NAME
|
|||
|
||||
final_path=$(ynh_app_setting_get $app final_path)
|
||||
domain=$(ynh_app_setting_get $app domain)
|
||||
db_name=$(ynh_app_setting_get $app db_name)
|
||||
|
||||
#=================================================
|
||||
# STANDARD BACKUP STEPS
|
||||
|
|
|
@ -20,9 +20,7 @@ domain=$(ynh_app_setting_get $app domain)
|
|||
|
||||
final_path=$(ynh_app_setting_get $app final_path)
|
||||
|
||||
sync_home=$(ynh_app_setting_get $app sync_home)
|
||||
sync_port=$(ynh_app_setting_get $app sync_port)
|
||||
gui_port=$(ynh_app_setting_get $app gui_port)
|
||||
|
||||
#=================================================
|
||||
# STANDARD REMOVE
|
||||
|
|
|
@ -30,7 +30,7 @@ app=$YNH_APP_INSTANCE_NAME
|
|||
domain=$(ynh_app_setting_get $app domain)
|
||||
path_url=$(ynh_app_setting_get $app path)
|
||||
final_path=$(ynh_app_setting_get $app final_path)
|
||||
db_name=$(ynh_app_setting_get $app db_name)
|
||||
sync_home=$(ynh_app_setting_get $app sync_home)
|
||||
|
||||
#=================================================
|
||||
# CHECK IF THE APP CAN BE RESTORED
|
||||
|
@ -74,6 +74,15 @@ chown -R "$app": $final_path
|
|||
|
||||
#=================================================
|
||||
# SPECIFIC RESTORATION
|
||||
#=================================================
|
||||
# RECREATE SYNC DIRECTORY
|
||||
#=================================================
|
||||
ynh_print_info "Recreating sync directory..."
|
||||
|
||||
# Make directories and set rights
|
||||
mkdir -p "$sync_home"
|
||||
chown -R "$app": "$sync_home"
|
||||
|
||||
#=================================================
|
||||
# RESTORE SYSTEMD
|
||||
#=================================================
|
||||
|
@ -102,8 +111,7 @@ systemctl reload nginx
|
|||
#=================================================
|
||||
ynh_print_info "Starting Syncthing services..."
|
||||
|
||||
ynh_systemd_action --action=start --service_name=$app --log_path=systemd
|
||||
#--line_match="Started $app"
|
||||
ynh_systemd_action --action=start --service_name=$app --log_path=systemd --line_match="Access the GUI via the following URL"
|
||||
|
||||
#=================================================
|
||||
# END OF SCRIPT
|
||||
|
|
Loading…
Add table
Reference in a new issue