ソースを参照

Update domain delete routine

Kristan Kenney 7 年 前
コミット
88ecae938a
1 ファイル変更9 行追加0 行削除
  1. 9 0
      func/domain.sh

+ 9 - 0
func/domain.sh

@@ -299,6 +299,7 @@ del_web_config() {
         conf="$HOMEDIR/$user/conf/web/$domain/$1.ssl.conf"
     fi
 
+    # Clean up legacy configuration files
     if [ -e "$conf" ]; then
         sed -i "\|$conf|d" /etc/$1/conf.d/hestia.conf
         rm -f $conf
@@ -319,6 +320,14 @@ del_web_config() {
             rm -f $conf
         fi
     fi
+
+    # Remove domain file symbolic links
+    if [ -f /etc/$WEB_SYSTEM/conf.d/domains/$domain.conf ]; then
+        rm -f /etc/$WEB_SYSTEM/conf.d/domains/$domain*.conf 
+    fi
+    if [ -f /etc/$PROXY_SYSTEM/conf.d/domains/$domain.conf ]; then
+        rm -f /etc/$PROXY_SYSTEM/conf.d/domains/$domain*.conf 
+    fi
 }
 
 # SSL certificate verification