1
0
Fork 0
puter/hosts/abacus/filebrowser.nix

26 lines
575 B
Nix
Raw Normal View History

2025-05-19 17:43:46 +02:00
{config, ...}: let
virtualHostName = "filebrowser.helveticanonstandard.net";
cfg = config.services.filebrowser;
in{
services.filebrowser = {
enable = true;
settings = {
address = "localhost";
port = 8090;
database = "/var/lib/filebrowser/filebrowser.db";
};
};
services.nginx.virtualHosts.${virtualHostName} = {
enableACME = true;
forceSSL = true;
locations."/".proxyPass =
let
host = cfg.settings.address;
port = builtins.toString cfg.settings.port;
in
"http://${host}:${port}";
};
}