first commit
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
server {
|
||||
listen 80;
|
||||
server_name recipe.example.com;
|
||||
|
||||
location /.well-known/acme-challenge/ {
|
||||
root /var/www/certbot;
|
||||
}
|
||||
|
||||
location / {
|
||||
return 301 https://$host$request_uri;
|
||||
}
|
||||
}
|
||||
|
||||
server {
|
||||
listen 443 ssl http2;
|
||||
server_name recipe.example.com;
|
||||
|
||||
# 실제 인증서 경로로 교체한다. Let's Encrypt/Caddy를 사용해도 된다.
|
||||
ssl_certificate /etc/letsencrypt/live/recipe.example.com/fullchain.pem;
|
||||
ssl_certificate_key /etc/letsencrypt/live/recipe.example.com/privkey.pem;
|
||||
|
||||
add_header X-Content-Type-Options nosniff always;
|
||||
add_header Referrer-Policy strict-origin-when-cross-origin always;
|
||||
client_max_body_size 2m;
|
||||
|
||||
location / {
|
||||
proxy_pass http://127.0.0.1:3000;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
proxy_read_timeout 120s;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user