Created
July 17, 2023 08:34
-
-
Save rafirh/92dc6ec2f2c3cf607874c1cbd75c6c59 to your computer and use it in GitHub Desktop.
NGINx Conf Example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
server_name <app-domain>; | |
access_log /var/log/nginx/<app-name>.access.log; | |
error_log /var/log/nginx/<app-name>.error.log; | |
location / { | |
include proxy_params; | |
proxy_pass http://0.0.0.0:<app-port>; | |
proxy_set_header Host $host; | |
proxy_set_header X-Forwared-Proto $scheme; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header X-Forward-For $proxy_add_x_forwarded_for; | |
proxy_set_header Upgrade $http_upgrade; | |
proxy_set_header Connection "Upgrade"; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment