Infini-OPTIPLEX: transfer services to Infini-DL360
This commit is contained in:
parent
253c57dd8f
commit
a9ccc13825
9 changed files with 7 additions and 7 deletions
|
@ -1,54 +0,0 @@
|
|||
{ config, pkgs, ... }:
|
||||
let
|
||||
address = "127.0.0.1";
|
||||
port = 8096;
|
||||
jellyfin = "http://${address}:${toString port}";
|
||||
proxyConfig = ''
|
||||
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-Protocol $scheme;
|
||||
proxy_set_header X-Forwarded-Host $http_host;
|
||||
'';
|
||||
in
|
||||
{
|
||||
services.nginx.virtualHosts."jellyfin.inx.moe" = config.common.nginx.ssl // {
|
||||
extraConfig = ''
|
||||
client_max_body_size 20M;
|
||||
'';
|
||||
|
||||
locations."= /" = {
|
||||
return = "302 https://$host/web/";
|
||||
};
|
||||
|
||||
locations."/" = {
|
||||
proxyPass = jellyfin;
|
||||
recommendedProxySettings = false;
|
||||
extraConfig = proxyConfig + ''
|
||||
proxy_buffering off;
|
||||
'';
|
||||
};
|
||||
|
||||
locations."= /web/" = {
|
||||
proxyPass = "${jellyfin}/web/index.html";
|
||||
recommendedProxySettings = false;
|
||||
extraConfig = proxyConfig;
|
||||
};
|
||||
|
||||
locations."/socket" = {
|
||||
proxyPass = jellyfin;
|
||||
proxyWebsockets = true;
|
||||
recommendedProxySettings = false;
|
||||
extraConfig = proxyConfig;
|
||||
};
|
||||
};
|
||||
|
||||
services.jellyfin = {
|
||||
enable = true;
|
||||
dataDir = "/srv/jellyfin";
|
||||
openFirewall = true;
|
||||
};
|
||||
|
||||
persist.directories = with config.services.jellyfin; [ dataDir cacheDir logDir ];
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue