Skip to content

Commit d0888e5

Browse files
authored
Merge branch 'staging/fixes' into main
2 parents 46f5c67 + ec64320 commit d0888e5

File tree

6 files changed

+283
-214
lines changed

6 files changed

+283
-214
lines changed

bin/v-add-sys-ip

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,7 @@ if [ ! -z "$PROXY_SYSTEM" ]; then
147147
sed -e "s/%ip%/$ip/g" \
148148
-e "s/%web_port%/$WEB_PORT/g" \
149149
-e "s/%proxy_port%/$PROXY_PORT/g" \
150+
-e "s/%proxy_ssl_port%/$PROXY_SSL_PORT/g" \
150151
> /etc/$PROXY_SYSTEM/conf.d/$ip.conf
151152

152153
# mod_extract_forwarded

install/deb/templates/web/nginx/proxy_ip.tpl

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,19 @@ server {
1212
}
1313
}
1414

15+
server {
16+
listen %ip%:%proxy_ssl_port% ssl http2;
17+
server_name _;
18+
ssl_certificate /usr/local/hestia/ssl/certificate.crt;
19+
ssl_certificate_key /usr/local/hestia/ssl/certificate.key;
20+
21+
return 301 http://$host$request_uri;
22+
23+
location / {
24+
root /var/www/document_errors/;
25+
}
26+
27+
location /error/ {
28+
alias /var/www/document_errors/;
29+
}
30+
}

install/hst-install-debian.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -811,7 +811,7 @@ fi
811811
if [ -d "$withdebs" ]; then
812812
software=$(echo "$software" | sed -e "s/hestia-nginx//")
813813
software=$(echo "$software" | sed -e "s/hestia-php//")
814-
software=$(echo "$software" | sed -e "s/hestia//")
814+
software=$(echo "$software" | sed -e "s/hestia=${HESTIA_INSTALL_VER}//")
815815
fi
816816

817817
#----------------------------------------------------------#

install/hst-install-ubuntu.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -794,7 +794,7 @@ fi
794794
if [ -d "$withdebs" ]; then
795795
software=$(echo "$software" | sed -e "s/hestia-nginx//")
796796
software=$(echo "$software" | sed -e "s/hestia-php//")
797-
software=$(echo "$software" | sed -e "s/hestia//")
797+
software=$(echo "$software" | sed -e "s/hestia=${HESTIA_INSTALL_VER}//")
798798
fi
799799
if [ "$release" = '16.04' ]; then
800800
software=$(echo "$software" | sed -e "s/libonig5/libonig2/")

install/upgrade/versions/1.3.0.sh

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,17 @@ for user in $($HESTIA/bin/v-list-sys-users plain); do
1515
chown $user:$user \
1616
$HOMEDIR/$user/.npm
1717
done
18+
19+
# Add default SSL Certificate config when ip is visited
20+
if [ "$PROXY_SYSTEM" = "nginx" ]; then
21+
echo "[ ! ] Update IP.conf"
22+
while read IP; do
23+
rm /etc/nginx/conf.d/$IP.conf
24+
cat $WEBTPL/$PROXY_SYSTEM/proxy_ip.tpl |\
25+
sed -e "s/%ip%/$IP/g" \
26+
-e "s/%web_port%/$WEB_PORT/g" \
27+
-e "s/%proxy_port%/$PROXY_PORT/g" \
28+
-e "s/%proxy_ssl_port%/$PROXY_SSL_PORT/g" \
29+
> /etc/$PROXY_SYSTEM/conf.d/$IP.conf
30+
done < <(ls $HESTIA/data/ips/)
31+
fi

0 commit comments

Comments
 (0)