tubearchivist/docker_assets/nginx.conf

56 lines
1010 B
Nginx Configuration File

server {
listen 8000;
location /cache/videos/ {
auth_request /api/ping/;
alias /cache/videos/;
}
location /cache/channels/ {
auth_request /api/ping/;
alias /cache/channels/;
}
location /cache/playlists/ {
auth_request /api/ping/;
alias /cache/playlists/;
}
location /media/ {
auth_request /api/ping/;
alias /youtube/;
types {
text/vtt vtt;
}
}
location /youtube/ {
auth_request /api/ping/;
alias /youtube/;
types {
video/mp4 mp4;
}
}
location /api {
include uwsgi_params;
uwsgi_pass localhost:8080;
}
location /admin {
include uwsgi_params;
uwsgi_pass localhost:8080;
}
location /static/ {
alias /app/staticfiles/;
}
root /app/static;
index index.html;
location / {
try_files $uri $uri/ /index.html =404;
}
}