Last active
February 25, 2019 18:04
-
-
Save dmytrostriletskyi/cce03d2aca0e2eaae3b8555eff252c0b to your computer and use it in GitHub Desktop.
This file contains hidden or 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
user www-data; | |
worker_processes auto; | |
pid /run/nginx.pid; | |
events { | |
worker_connections 768; | |
} | |
http { | |
server { | |
listen 443 ssl; | |
server_name websitenamewithdomain; | |
ssl_certificate /etc/letsencrypt/live/websitenamewithdomain/fullchain.pem; | |
ssl_certificate_key /etc/letsencrypt/live/websitenamewithdomain/privkey.pem; | |
include /etc/letsencrypt/options-ssl-nginx.conf; | |
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; | |
error_page 500 502 503 504 /custom_50x_rb.html; | |
location = /custom_50x_rb.html { | |
root /usr/share/nginx/html; | |
internal; | |
} | |
location / { | |
proxy_read_timeout 90; | |
proxy_set_header X-Forwarded-Host $host:$server_port; | |
proxy_set_header X-Forwarded-Server $host; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
proxy_set_header X-Forwarded-Proto $scheme; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_pass http://127.0.0.1:8080; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment