From 55d2f863f9c4a55e391949ddd57b4a3b396496c4 Mon Sep 17 00:00:00 2001 From: Rodolphe Robles Date: Sat, 4 Apr 2020 09:18:57 +0200 Subject: [PATCH] change the hook post_upgrade --- hooks/post_app_upgrade | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/hooks/post_app_upgrade b/hooks/post_app_upgrade index 8744dd3..96a858b 100644 --- a/hooks/post_app_upgrade +++ b/hooks/post_app_upgrade @@ -15,18 +15,19 @@ source /usr/share/yunohost/helpers app=$YNH_APP_INSTANCE_NAME final_path=/var/www/$app +#================================================= +# Change options in file config.dist.php +# and copy in config.local.php +#================================================= + +sudo cp -a $final_path/garradin/config.dist.php $final_path/garradin/config.local.php + #================================================= # backup the bdd #================================================= sudo cp -a /tmp/association.sqlite $final_path/association.sqlite sudo cp -avr /tmp/squelettes $final_path/www/squelettes -#================================================= -# Change options in file config.dist.php -# and copy in config.local.php -#================================================= - -sudo cp -a /var/www/garradin/config.dist.php var/www/garradin/config.local.php # ynh_replace_string --match_string="const ROOT = __DIR__;" --replace_string="const ROOT = /var/www/garradin;" --target_file="$final_path/config.local.php" ynh_replace_string --match_string="const PREFER_HTTPS = false;" --replace_string="const PREFER_HTTPS = true;" --target_file="$final_path/config.local.php"