Skip to content

Commit 3bbce4c

Browse files
committed
splited port variable to proxy and web
1 parent e11a13c commit 3bbce4c

File tree

9 files changed

+14
-12
lines changed

9 files changed

+14
-12
lines changed

data/templates/apache_default.stpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<VirtualHost %ip%:%port%>
1+
<VirtualHost %ip%:%web_ssl_port%>
22

33
ServerName %domain_idn%
44
ServerAlias %alias_idn%

data/templates/apache_default.tpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<VirtualHost %ip%:%port%>
1+
<VirtualHost %ip%:%web_port%>
22

33
ServerName %domain_idn%
44
ServerAlias %alias_idn%

data/templates/apache_phpcgi.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ domain="$2"
55
ip="$3"
66
home_dir="$4"
77
docroot="$5"
8-
port="$6"
98

109
wrapper_script='#!/usr/bin/php-cgi -cphp5-cgi.ini'
1110
wrapper_file="$home_dir/$user/domains/$domain/cgi-bin/php"

data/templates/apache_phpcgi.stpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<VirtualHost %ip%:%port%>
1+
<VirtualHost %ip%:%web_ssl_port%>
22

33
ServerName %domain_idn%
44
ServerAlias %alias_idn%

data/templates/apache_phpcgi.tpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<VirtualHost %ip%:%port%>
1+
<VirtualHost %ip%:%web_port%>
22

33
ServerName %domain_idn%
44
ServerAlias %alias_idn%

data/templates/apache_unlim.stpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<VirtualHost %ip%:%port%>
1+
<VirtualHost %ip%:%web_ssl_port%>
22

33
ServerName %domain_idn%
44
ServerAlias %alias_idn%

data/templates/apache_unlim.tpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<VirtualHost %ip%:%port%>
1+
<VirtualHost %ip%:%web_port%>
22

33
ServerName %domain_idn%
44
ServerAlias %alias_idn%

data/templates/ngingx_vhost_default.tpl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
server {
2-
listen %ip%:%proxy_port%;
3-
server_name %domain_idn% %alias%;
2+
listen %ip%:%proxy_ssl_port%;
3+
server_name %domain_idn% %alias_idn%;
44
server_name_in_redirect off;
55
#error_log /var/log/httpd/domains/%domain%.error.log error;
66
77
location / {
8-
proxy_pass http://%ip%:%port%;
8+
proxy_pass http://%ip%:%web_ssl_port%;
99
1010
location ~* ^.+\.(%extentions%)$ {
1111
root %docroot%;
@@ -22,7 +22,7 @@ server {
2222
}
2323

2424
location @fallback {
25-
proxy_pass http://%ip%:%port%;
25+
proxy_pass http://%ip%:%web_ssl_port%;
2626
}
2727

2828
location ~ /\.ht {deny all;}

func/domain_func.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,10 @@ httpd_add_config() {
223223
# Adding template to config
224224
cat $tpl_file | \
225225
sed -e "s/%ip%/$ip/g" \
226-
-e "s/%port%/$port/g" \
226+
-e "s/%web_port%/$web_port/g" \
227+
-e "s/%web_ssl_port%/$web_ssl_port/g" \
228+
-e "s/%proxy_port%/$proxy_port/g" \
229+
-e "s/%proxy_ssl_port%/$proxy_ssl_port/g" \
227230
-e "s/%domain_idn%/$domain_idn/g" \
228231
-e "s/%domain%/$domain/g" \
229232
-e "s/%user%/$user/g" \

0 commit comments

Comments
 (0)