From 37ea59c4d44569b71fc136ca2ae3d96e95c2ed00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 27 Oct 2023 22:03:12 +0200 Subject: [PATCH] cleaning --- scripts/install | 4 ++-- scripts/upgrade | 11 ++++++++++- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/scripts/install b/scripts/install index ec9b1a1..b1e49e2 100755 --- a/scripts/install +++ b/scripts/install @@ -49,7 +49,7 @@ ynh_add_nginx_config #================================================= ynh_script_progression --message="Adding a configuration file..." --weight=1 -ynh_add_config --template="../conf/config.ini" --destination="$install_dir/config.ini" +ynh_add_config --template="config.ini" --destination="$install_dir/config.ini" chmod 400 "$install_dir/config.ini" chown $app:$app "$install_dir/config.ini" @@ -59,7 +59,7 @@ chown $app:$app "$install_dir/config.ini" #================================================= ynh_script_progression --message="Setuping a cron..." --weight=1 -ynh_add_config --template="../conf/cron" --destination="/etc/cron.d/$app" +ynh_add_config --template="cron" --destination="/etc/cron.d/$app" chown root: "/etc/cron.d/$app" chmod 644 "/etc/cron.d/$app" diff --git a/scripts/upgrade b/scripts/upgrade index 05adff2..ac9fa47 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -70,11 +70,20 @@ ynh_add_nginx_config #================================================= ynh_script_progression --message="Updating a configuration file..." --weight=1 -ynh_add_config --template="../conf/config.ini" --destination="$install_dir/config.ini" +ynh_add_config --template="config.ini" --destination="$install_dir/config.ini" chmod 400 "$install_dir/config.ini" chown $app:$app "$install_dir/config.ini" +#================================================= +# SETUP A CRON +#================================================= +ynh_script_progression --message="Setuping a cron..." --weight=1 + +ynh_add_config --template="cron" --destination="/etc/cron.d/$app" +chown root: "/etc/cron.d/$app" +chmod 644 "/etc/cron.d/$app" + #================================================= # END OF SCRIPT #=================================================