Skip to content

Commit

Permalink
enhance GATEWAY_FASTCGI_HTTPS management script
Browse files Browse the repository at this point in the history
  • Loading branch information
moctardiouf authored Sep 7, 2023
1 parent 1b39ba7 commit e5a35c3
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions docker/nginx/root/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,11 @@ fi

if [ ! -z "$GATEWAY_FASTCGI_HTTPS" ]; then
echo "GATEWAY_FASTCGI_HTTPS is defined : $GATEWAY_FASTCGI_HTTPS"
GATEWAY_FASTCGI_HTTPS="fastcgi_param HTTPS $GATEWAY_FASTCGI_HTTPS;"
if [ $GATEWAY_FASTCGI_HTTPS == "on" || $GATEWAY_FASTCGI_HTTPS == "1" ]; then
GATEWAY_FASTCGI_HTTPS=`echo $GATEWAY_FASTCGI_HTTPS` ";fastcgi_param SERVER_PORT 443;"
if [ "$GATEWAY_FASTCGI_HTTPS" = "on" ] || [ "$GATEWAY_FASTCGI_HTTPS" = "1" ];then
echo "SETTING SERVER_PORT TO: 443"
GATEWAY_FASTCGI_HTTPS="fastcgi_param HTTPS on;fastcgi_param SERVER_PORT 443;"
else
GATEWAY_FASTCGI_HTTPS="fastcgi_param HTTPS $GATEWAY_FASTCGI_HTTPS;"
fi
else
echo "NO GATEWAY_FASTCGI_HTTPS is defined"
Expand Down

0 comments on commit e5a35c3

Please sign in to comment.