From 19beced228332ec3e794655ec7fe0d0109668d0a Mon Sep 17 00:00:00 2001 From: Serghey Rodin Date: Thu, 23 Jun 2011 00:24:22 +0300 Subject: [PATCH] fixed no_web_domains case --- bin/v_rebuild_web_domains | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/bin/v_rebuild_web_domains b/bin/v_rebuild_web_domains index 391666ee9..a4e9a6258 100755 --- a/bin/v_rebuild_web_domains +++ b/bin/v_rebuild_web_domains @@ -105,12 +105,14 @@ done # Renaming tmp config tmp_conf="$V_HOME/$user/conf/tmp_httpd.conf" conf="$V_HOME/$user/conf/httpd.conf" -mv $tmp_conf $conf +if [ -e "$tmp_conf" ]; then + mv $tmp_conf $conf +fi # Checking include in main httpd.conf main_conf='/etc/httpd/conf.d/vesta.conf' main_conf_check=$(grep "$conf" $main_conf ) -if [ -z "$main_conf_check" ]; then +if [ ! -z "$domains" ] && [ -z "$main_conf_check" ]; then echo "Include $conf" >>$main_conf fi