mirror of
https://github.com/blakeblackshear/frigate.git
synced 2024-12-19 19:06:16 +01:00
update nginx config
This commit is contained in:
parent
3941ce4ad1
commit
59daa6597b
@ -18,12 +18,13 @@ http {
|
||||
access_log /var/log/nginx/access.log main;
|
||||
|
||||
sendfile on;
|
||||
client_max_body_size 50M;
|
||||
#tcp_nopush on;
|
||||
|
||||
keepalive_timeout 65;
|
||||
|
||||
#gzip on;
|
||||
upstream frigate_api {
|
||||
server localhost:5000;
|
||||
keepalive 1024;
|
||||
}
|
||||
|
||||
server {
|
||||
listen 80;
|
||||
@ -51,7 +52,7 @@ http {
|
||||
root /tmp;
|
||||
}
|
||||
|
||||
location /frigate/ {
|
||||
location /clips/ {
|
||||
add_header 'Access-Control-Allow-Origin' "$http_origin" always;
|
||||
add_header 'Access-Control-Allow-Credentials' 'true';
|
||||
add_header 'Access-Control-Expose-Headers' 'Content-Length';
|
||||
@ -69,7 +70,15 @@ http {
|
||||
}
|
||||
|
||||
autoindex on;
|
||||
root /media;
|
||||
root /media/frigate;
|
||||
}
|
||||
|
||||
location / {
|
||||
proxy_pass http://frigate_api/;
|
||||
proxy_pass_request_headers on;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user