From 26f5de3d51169df167a972dcb371d5039096bbf5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antoine=20Beaupr=C3=A9?= Date: Fri, 23 Jun 2006 03:12:26 +0000 Subject: [PATCH] =?UTF-8?q?ne=20plus=20cr=C3=A9er=20les=20sous-domaines=20?= =?UTF-8?q?par=20d=C3=A9faut=20a=20la=20creation=20d'un=20domaine=20dans?= =?UTF-8?q?=20update=5Fdomaines,=20m=5Fdom.php:add=5Fdomain()=20s'en=20cha?= =?UTF-8?q?rge=20d=C3=A9j=C3=A0.=20Closes:=20#719?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/update_domains.sh | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/src/update_domains.sh b/src/update_domains.sh index a41009ca..b9adc9d1 100755 --- a/src/update_domains.sh +++ b/src/update_domains.sh @@ -235,7 +235,7 @@ add_host() { delete_host "$domain" "$host" - if [ "$host" = "@" ]; then + if [ "$host" = "@" -o -z "$host" ]; then change_host_ip "$domain" "$PUBLIC_IP" || true fqdn="$domain" else @@ -454,18 +454,8 @@ while read user domain mx are_we_dns are_we_mx action ; do case "$action" in $ACTION_INSERT) - # default symlinks - ln -snf "${HTML_HOME}/${USER_LETTER}/$user" \ - "${HTTP_DNS}/${DOMAIN_LETTER}/$domain" - ln -snf "${HTML_HOME}/${USER_LETTER}/$user" \ - "${HTTP_DNS}/${DOMAIN_LETTER}/www.$domain" - ln -snf "${WEBMAIL_DIR}" "${HTTP_DNS}/${DOMAIN_LETTER}/mail.$domain" - if [ "$are_we_dns" = "$YES" ] ; then init_zone "$domain" - change_host_ip "$domain" "$PUBLIC_IP" - change_host_ip "$domain" "$PUBLIC_IP" www - change_host_ip "$domain" "$PUBLIC_IP" mail fi ;; @@ -509,7 +499,7 @@ IFS=" " while read user domain host value type action; do IFS="$OLD_IFS" - if [ "$host" = "@" ]; then + if [ "$host" = "@" -o -z "$host" ]; then FQDN="$domain" else FQDN="$host.$domain"