feat(etna): add zipline
This commit is contained in:
parent
63d99f2062
commit
e2f4de4538
5 changed files with 62 additions and 0 deletions
|
@ -68,6 +68,7 @@ in
|
|||
./uku.nix
|
||||
./ups.nix
|
||||
./vaultwarden.nix
|
||||
./zipline.nix
|
||||
];
|
||||
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
|
|
32
systems/etna/zipline.nix
Normal file
32
systems/etna/zipline.nix
Normal file
|
@ -0,0 +1,32 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
config,
|
||||
_utils,
|
||||
...
|
||||
}:
|
||||
let
|
||||
envFile = _utils.setupSingleSecret config "ziplineEnv" { };
|
||||
in
|
||||
{
|
||||
imports = [ envFile.generate ];
|
||||
|
||||
services.zipline = {
|
||||
enable = true;
|
||||
database.createLocally = true;
|
||||
environmentFiles = [ envFile.path ];
|
||||
|
||||
settings = {
|
||||
CORE_HOSTNAME = "0.0.0.0";
|
||||
CORE_PORT = 3001;
|
||||
DATASOURCE_TYPE = "local";
|
||||
DATASOURCE_LOCAL_DIRECTORY = "/data/zipline";
|
||||
FFMPEG_PATH = lib.getExe pkgs.ffmpeg;
|
||||
};
|
||||
};
|
||||
|
||||
systemd.services.zipline.serviceConfig = {
|
||||
ReadWritePaths = [ "/data/zipline" ];
|
||||
ProtectProc = lib.mkForce "default";
|
||||
};
|
||||
}
|
|
@ -34,5 +34,19 @@
|
|||
recommendedProxySettings = true;
|
||||
};
|
||||
};
|
||||
|
||||
"zipline.uku3lig.net" = {
|
||||
serverAliases = [ "v.uku.moe" ];
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
locations."/" = {
|
||||
proxyPass = "http://etna:3001";
|
||||
recommendedProxySettings = true;
|
||||
};
|
||||
|
||||
extraConfig = ''
|
||||
client_max_body_size 1000M;
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue