Initial commit
This commit is contained in:
commit
737c710be9
69
jellyfin.conf
Normal file
69
jellyfin.conf
Normal file
@ -0,0 +1,69 @@
|
||||
# /etc/nginx/sites-available/jellyfin
|
||||
map $http_upgrade $connection_upgrade {
|
||||
default upgrade;
|
||||
'' close;
|
||||
}
|
||||
|
||||
server {
|
||||
listen 80;
|
||||
server_name nik4nao.home.arpa;
|
||||
|
||||
# Jellyfin (unchanged)
|
||||
location = /jellyfin { return 302 /jellyfin/; }
|
||||
location /jellyfin/ {
|
||||
proxy_pass http://192.168.7.96:8096/;
|
||||
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_set_header X-Forwarded-Prefix /jellyfin;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection $connection_upgrade;
|
||||
proxy_buffering off;
|
||||
client_max_body_size 0;
|
||||
proxy_read_timeout 600;
|
||||
proxy_send_timeout 600;
|
||||
send_timeout 600;
|
||||
}
|
||||
|
||||
# ---- Pi-hole at /admin/ (no subpath tricks) ----
|
||||
|
||||
# Optional: make / and /pihole go to /admin/
|
||||
location = / { return 302 /admin/; }
|
||||
location = /pihole { return 302 /admin/; }
|
||||
location /pihole/ { return 301 /admin/; }
|
||||
|
||||
# Pi-hole UI
|
||||
location /admin/ {
|
||||
proxy_pass http://127.0.0.1:8081/admin/;
|
||||
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Forwarded-Host $host;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Connection "";
|
||||
|
||||
proxy_buffering off;
|
||||
client_max_body_size 0;
|
||||
proxy_read_timeout 600;
|
||||
proxy_send_timeout 600;
|
||||
send_timeout 600;
|
||||
}
|
||||
|
||||
# Pi-hole API (some UI calls hit /api)
|
||||
location /api/ {
|
||||
proxy_pass http://127.0.0.1:8081/api/;
|
||||
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Forwarded-Host $host;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Connection "";
|
||||
}
|
||||
}
|
||||
16
proxy-common.conf
Normal file
16
proxy-common.conf
Normal file
@ -0,0 +1,16 @@
|
||||
# Common reverse-proxy headers
|
||||
proxy_set_header Host $http_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_http_version 1.1;
|
||||
proxy_set_header Connection "";
|
||||
|
||||
# Reasonable timeouts (uploads/streams)
|
||||
client_max_body_size 0;
|
||||
proxy_read_timeout 600;
|
||||
proxy_send_timeout 600;
|
||||
send_timeout 600;
|
||||
|
||||
# Don’t cache proxied errors by mistake
|
||||
proxy_buffering off;
|
||||
Loading…
x
Reference in New Issue
Block a user