initial config commit
This commit is contained in:
parent
f8980b6805
commit
f3dc1d15ff
79 changed files with 2725 additions and 0 deletions
34
modules/nixos/features/immich.nix
Normal file
34
modules/nixos/features/immich.nix
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
feature = "immich";
|
||||
port = "2283";
|
||||
in
|
||||
{
|
||||
config = lib.mkIf config.${feature}.enable {
|
||||
services.${feature} = {
|
||||
enable = true;
|
||||
port = builtins.fromJSON "${port}";
|
||||
mediaLocation = "/srv/${feature}";
|
||||
};
|
||||
|
||||
# reverse proxy
|
||||
services.nginx = {
|
||||
clientMaxBodySize = "50000M";
|
||||
|
||||
virtualHosts."${feature}.fi33.buzz" = {
|
||||
forceSSL = true;
|
||||
useACMEHost = "fi33.buzz";
|
||||
locations."/" = {
|
||||
proxyPass = "http://[::1]:${port}";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
options.${feature}.enable = lib.mkEnableOption "enables ${feature}";
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue