Update v-change-web-domain-proxy-tpl

This commit is contained in:
Made I.T 2017-10-23 14:25:52 +02:00 committed by GitHub
commit cac3b0617f

View file

@ -54,11 +54,26 @@ is_proxy_template_valid $template
# Parsing domain values # Parsing domain values
get_domain_values 'web' get_domain_values 'web'
local_ip=$(get_real_ip $IP) local_ip=$(get_real_ip $IP)
ipv6=$IP6
# Delete old vhost # Deleting vhost configuration IPv4
del_web_config "$PROXY_SYSTEM" "$PROXY.tpl" if [ ! -z "$local_ip" ]; then
if [ "$SSL" = 'yes' ]; then old=$local_ip
del_web_config "$PROXY_SYSTEM" "$PROXY.stpl" # Deleting proxy
del_web_config "$PROXY_SYSTEM" "$PROXY.tpl"
if [ "$SSL" = 'yes' ]; then
del_web_config "$PROXY_SYSTEM" "$PROXY.stpl"
fi
fi
# Deleting domain
if [ ! -z "$IP6" ]; then
old=$IP6
del_web_config "$PROXY_SYSTEM" "$PROXY.tpl"
if [ "$SSL" = 'yes' ]; then
del_web_config "$PROXY_SYSTEM" "$PROXY.stpl"
fi
fi fi
# Add new vhost # Add new vhost