improving template structure

This commit is contained in:
Serghey Rodin 2013-04-03 23:18:51 +03:00
commit cd69b7bcdf
23 changed files with 135 additions and 88 deletions

View file

@ -44,7 +44,7 @@ is_object_unsuspended 'web' 'DOMAIN' "$domain"
# Get template name
get_domain_values 'web'
tpl_file="$WEBTPL/apache_$TPL.tpl"
tpl_file="$WEBTPL/apache/$TPL.tpl"
conf="$HOMEDIR/$user/conf/web/httpd.conf"
ip=$(get_real_ip $IP)
@ -60,7 +60,7 @@ fi
# Checking ssl
if [ "$SSL" = 'yes' ]; then
tpl_file="$WEBTPL/apache_$TPL.stpl"
tpl_file="$WEBTPL/apache/$TPL.stpl"
conf="$HOMEDIR/$user/conf/web/shttpd.conf"
del_web_config
@ -71,12 +71,12 @@ fi
# Checking nginx
if [ ! -z "$NGINX" ]; then
tpl_file="$WEBTPL/nginx_$NGINX.tpl"
tpl_file="$WEBTPL/nginx/$NGINX.tpl"
conf="$HOMEDIR/$user/conf/web/nginx.conf"
del_web_config
if [ "$SSL" = 'yes' ]; then
tpl_file="$WEBTPL/nginx_$NGINX.stpl"
tpl_file="$WEBTPL/nginx/$NGINX.stpl"
conf="$HOMEDIR/$user/conf/web/snginx.conf"
del_web_config
fi