diff --git a/scripts/install b/scripts/install index 5a99d22..894359c 100644 --- a/scripts/install +++ b/scripts/install @@ -103,7 +103,7 @@ ynh_setup_source --dest_dir="$final_path/include/plugins/build/preventautoscroll chmod 750 "$final_path" chmod -R o-rwx "$final_path" -chown -R root:$app "$final_path" +chown -R $app:$app "$final_path" #================================================= # NGINX CONFIGURATION @@ -124,6 +124,13 @@ phpversion=$(ynh_app_setting_get --app=$app --key=phpversion) #================================================= # SPECIFIC SETUP +#================================================= +# SET THE CRON FILE +#================================================= +ynh_script_progression --message="Setting the cron file..." + +ynh_add_config --template="../conf/cron" --destination="/etc/cron.d/$app" + #================================================= # ADD A CONFIGURATION #================================================= @@ -195,13 +202,6 @@ ynh_permission_update --permission="main" --remove="visitors" ynh_secure_remove --file="$final_path/setup" -#================================================= -# SET THE CRON FILE -#================================================= -ynh_script_progression --message="Setting the cron file..." - -ynh_add_config --template="../conf/cron" --destination="/etc/cron.d/$app" - #================================================= # GENERIC FINALIZATION #================================================= diff --git a/scripts/restore b/scripts/restore index 036881c..f0df46e 100644 --- a/scripts/restore +++ b/scripts/restore @@ -70,7 +70,7 @@ ynh_restore_file --origin_path="$final_path" chmod 750 "$final_path" chmod -R o-rwx "$final_path" -chown -R root:$app "$final_path" +chown -R $app:$app "$final_path" #================================================= # RESTORE THE PHP-FPM CONFIGURATION diff --git a/scripts/upgrade b/scripts/upgrade index 4eebc48..32704e1 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -105,7 +105,7 @@ fi chmod 750 "$final_path" chmod -R o-rwx "$final_path" -chown -R root:$app "$final_path" +chown -R $app:$app "$final_path" #================================================= # NGINX CONFIGURATION