20 lines
370 B
Plaintext
20 lines
370 B
Plaintext
server {
|
|||
|
|
listen 80 default_server;
|
||
|
|
listen [::]:80 default_server;
|
||
|
|
|
||
|
|
server_name _;
|
||
|
|
|
||
|
|
root /var/www/todolist;
|
||
|
|
index index.html;
|
||
|
|
|
||
|
|
location / {
|
||
|
|
try_files $uri $uri/ /index.html;
|
||
|
|
}
|
||
|
|
|
||
|
|
location /api/ {
|
||
|
|
proxy_pass http://127.0.0.1:8000/;
|
||
|
|
proxy_set_header Host $host;
|
||
|
|
proxy_set_header X-Real-IP $remote_addr;
|
||
|
|
}
|
||
|
|
}
|