2022-09-21 22:37:01 +05:30
|
|
|
(global) {
|
2021-09-25 19:14:58 +05:30
|
|
|
header {
|
|
|
|
# disable FLoC tracking
|
|
|
|
Permissions-Policy interest-cohort=()
|
2021-09-19 04:29:50 +05:30
|
|
|
|
2021-09-25 19:14:58 +05:30
|
|
|
# enable HSTS
|
|
|
|
Strict-Transport-Security max-age=31536000;
|
2021-09-19 04:29:50 +05:30
|
|
|
|
2021-09-25 19:14:58 +05:30
|
|
|
# keep referrer data off
|
|
|
|
Referrer-Policy no-referrer
|
2021-09-19 04:29:50 +05:30
|
|
|
|
2021-09-25 19:14:58 +05:30
|
|
|
# prevent for appearing in search engine for private instances (option)
|
|
|
|
#X-Robots-Tag noindex
|
|
|
|
}
|
2021-08-25 13:21:41 +05:30
|
|
|
}
|
|
|
|
|
2022-09-21 22:37:01 +05:30
|
|
|
FRONTEND_HOSTNAME {
|
2024-06-20 23:42:08 +05:30
|
|
|
reverse_proxy piped-frontend:80
|
2022-09-21 22:37:01 +05:30
|
|
|
import global
|
|
|
|
}
|
|
|
|
|
2021-08-25 13:21:41 +05:30
|
|
|
BACKEND_HOSTNAME {
|
2022-11-03 23:10:46 +05:30
|
|
|
reverse_proxy nginx:80
|
2022-09-21 22:37:01 +05:30
|
|
|
import global
|
2021-08-25 13:21:41 +05:30
|
|
|
}
|
|
|
|
|
|
|
|
PROXY_HOSTNAME {
|
2021-09-25 19:14:58 +05:30
|
|
|
@ytproxy path /videoplayback* /api/v4/* /api/manifest/*
|
2022-09-21 22:37:01 +05:30
|
|
|
import global
|
2021-08-25 13:21:41 +05:30
|
|
|
|
2021-09-25 19:14:58 +05:30
|
|
|
route {
|
|
|
|
header @ytproxy {
|
|
|
|
Cache-Control private always
|
|
|
|
}
|
2021-09-19 04:29:50 +05:30
|
|
|
|
2021-09-25 19:14:58 +05:30
|
|
|
header / {
|
|
|
|
Cache-Control "public, max-age=604800"
|
|
|
|
}
|
2021-09-19 04:29:50 +05:30
|
|
|
|
2022-11-03 22:58:09 +05:30
|
|
|
reverse_proxy unix//var/run/ytproxy/actix.sock {
|
2021-09-25 19:14:58 +05:30
|
|
|
header_up -CF-Connecting-IP
|
|
|
|
header_up -X-Forwarded-For
|
|
|
|
header_down -etag
|
|
|
|
header_down -alt-svc
|
|
|
|
}
|
|
|
|
}
|
2021-08-25 13:21:41 +05:30
|
|
|
}
|