mirror of
https://github.com/YunoHost-Apps/radicale_ynh.git
synced 2024-09-03 20:16:14 +02:00
Update restore
This commit is contained in:
parent
61a681c79c
commit
1d31c66752
1 changed files with 7 additions and 8 deletions
|
@ -40,9 +40,9 @@ phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
|
|||
ynh_script_progression --message="Validating restoration parameters..."
|
||||
|
||||
test ! -d $final_path \
|
||||
|| ynh_die "There is already a directory: $final_path "
|
||||
|| ynh_die --message="There is already a directory: $final_path "
|
||||
test ! -d "/opt/yunohost/$app" \
|
||||
|| ynh_die "There is already a directory: /opt/yunohost/$app "
|
||||
|| ynh_die --message="There is already a directory: /opt/yunohost/$app "
|
||||
|
||||
#=================================================
|
||||
# ACTIVATE MAINTENANCE MODE
|
||||
|
@ -71,11 +71,9 @@ ynh_system_user_create --username=$app --home_dir="$final_path"
|
|||
#=================================================
|
||||
# RESTORE THE APP MAIN DIR
|
||||
#=================================================
|
||||
ynh_script_progression --message="Restore the app main directory"
|
||||
ynh_script_progression --message="Restoring the app main directory..."
|
||||
|
||||
ynh_restore_file "$final_path"
|
||||
mkdir -p /opt/yunohost
|
||||
ynh_restore_file "/opt/yunohost/$app"
|
||||
ynh_restore_file --origin_path="$final_path"
|
||||
|
||||
#=================================================
|
||||
# RESTORE THE PHP-FPM CONFIGURATION
|
||||
|
@ -101,8 +99,6 @@ ynh_install_app_dependencies $pkg_dependencies
|
|||
# RESTORE USER RIGHTS
|
||||
#=================================================
|
||||
|
||||
chown radicale: -R /opt/yunohost/$app
|
||||
|
||||
chown -R radicale: $final_path
|
||||
mkdir -p /var/log/$app
|
||||
touch /var/log/$app/$app.log
|
||||
|
@ -114,6 +110,9 @@ chown radicale -R /var/log/$app
|
|||
ynh_script_progression --message="Restoring various files..."
|
||||
|
||||
ynh_restore_file --origin_path="/etc/$app"
|
||||
mkdir -p /opt/yunohost
|
||||
ynh_restore_file --origin_path="/opt/yunohost/$app"
|
||||
chown radicale: -R /opt/yunohost/$app
|
||||
|
||||
#=================================================
|
||||
# RESTORE THE UWSGI CONFIG
|
||||
|
|
Loading…
Add table
Reference in a new issue