From 04ed847e18abc8f266ea35e6b84012bc878f21f2 Mon Sep 17 00:00:00 2001 From: Chtixof Date: Wed, 20 May 2015 23:07:46 +0200 Subject: [PATCH] Do not overwrite setup.ini --- scripts/install | 3 +++ scripts/upgrade | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/install b/scripts/install index d236b93..0b57597 100644 --- a/scripts/install +++ b/scripts/install @@ -17,6 +17,9 @@ fi final_path=/var/www/$app sudo mkdir -p $final_path sudo cp -a ../sources/* $final_path +if [[ ! -f ${final_path}/conf/setup.ini ]] ; then + sudo cp ${final_path}/conf/sample/setup.ini .. +fi sudo chown -R www-data: $final_path # Modify Nginx configuration file and copy it to Nginx conf directory diff --git a/scripts/upgrade b/scripts/upgrade index 1f8e0a5..819884f 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -12,7 +12,9 @@ path=${path%/} final_path=/var/www/$app sudo mkdir -p $final_path sudo cp -a ../sources/* $final_path - +if [[ ! -f ${final_path}/conf/setup.ini ]] ; then + sudo cp ${final_path}/conf/sample/setup.ini .. +fi # Modify Nginx configuration file and copy it to Nginx conf directory sed -i "s@PATHTOCHANGE@$path@g" ../conf/nginx.conf sed -i "s@WWWPATH@$final_path@g" ../conf/nginx.conf