|
@@ -43,7 +43,7 @@ if [ "$SSL" != 'yes' ]; then
|
|
|
fi
|
|
fi
|
|
|
|
|
|
|
|
# Check if proxy is active
|
|
# Check if proxy is active
|
|
|
-if [ ! -z "$PROXY_SYSTEM" ] || [ ! -z "$PROXY" ]; then
|
|
|
|
|
|
|
+if [ ! -z "$PROXY_SYSTEM" ]; then
|
|
|
if ! grep --quiet "forcessl" $HESTIA/data/templates/web/nginx/default.tpl; then
|
|
if ! grep --quiet "forcessl" $HESTIA/data/templates/web/nginx/default.tpl; then
|
|
|
$BIN/v-update-web-templates
|
|
$BIN/v-update-web-templates
|
|
|
fi
|
|
fi
|
|
@@ -56,7 +56,7 @@ else
|
|
|
fi
|
|
fi
|
|
|
|
|
|
|
|
# Insert redirect commands
|
|
# Insert redirect commands
|
|
|
-if [ ! -z $PROXY ]; then
|
|
|
|
|
|
|
+if [ ! -z "$PROXY_SYSTEM" ] || [ "$WEB_SYSTEM" = 'nginx' ]; then
|
|
|
echo 'return 301 https://$host$request_uri;' > $forcessl
|
|
echo 'return 301 https://$host$request_uri;' > $forcessl
|
|
|
else
|
|
else
|
|
|
echo 'RewriteEngine On' > $forcessl
|
|
echo 'RewriteEngine On' > $forcessl
|