-
Notifications
You must be signed in to change notification settings - Fork 0
/
nginx.conf
52 lines (40 loc) · 1.38 KB
/
nginx.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
server {
listen 80;
client_max_body_size 20M;
server_name www.lockfestival.com;
return 301 https://www.lockfestival.com$request_uri;
}
server {
listen 443 ssl;
client_max_body_size 20M;
server_name www.lockfestival.com lockfestival.com;
# Certificate
ssl_certificate /etc/ssl/cert.pem;
# Private Key
ssl_certificate_key /etc/ssl/key.pem;
location ^~ /socket.io {
proxy_pass http://backend:3000/socket.io;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Host $host;
}
location /api {
proxy_buffer_size 128k;
proxy_buffers 4 256k;
proxy_busy_buffers_size 256k;
proxy_pass http://backend:3000; # sprint port
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;
}
location /image {
proxy_pass https://kr.object.private.ncloudstorage.com/lockfestival/image;
}
location / {
root /usr/share/nginx/html;
index index.html index.htm;
try_files $uri $uri/ /index.html;
}
}