alyssum/immich: enable public proxy
Some checks are pending
CI / Build linux-lava for x86_64-linux (push) Waiting to run
Some checks are pending
CI / Build linux-lava for x86_64-linux (push) Waiting to run
This commit is contained in:
parent
59a6e63c6a
commit
6c83cb4e67
1 changed files with 28 additions and 3 deletions
|
|
@ -1,8 +1,17 @@
|
||||||
{ config, ... }: {
|
{ config, ... }:
|
||||||
|
let
|
||||||
|
fqdn = "photos.lava.moe";
|
||||||
|
shareFqdn = "memo.lava.moe";
|
||||||
|
in {
|
||||||
services.immich = {
|
services.immich = {
|
||||||
enable = true;
|
enable = true;
|
||||||
accelerationDevices = null;
|
accelerationDevices = null;
|
||||||
settings.server.externalDomain = "https://photos.lava.moe";
|
settings.server.externalDomain = "https://${shareFqdn}";
|
||||||
|
};
|
||||||
|
|
||||||
|
services.immich-public-proxy = {
|
||||||
|
enable = true;
|
||||||
|
immichUrl = "https://${fqdn}";
|
||||||
};
|
};
|
||||||
|
|
||||||
me.binds."/var/lib/immich" = "/flower/immich";
|
me.binds."/var/lib/immich" = "/flower/immich";
|
||||||
|
|
@ -12,7 +21,7 @@
|
||||||
hardware.graphics.enable = true;
|
hardware.graphics.enable = true;
|
||||||
users.users.immich.extraGroups = [ "video" "render" ];
|
users.users.immich.extraGroups = [ "video" "render" ];
|
||||||
|
|
||||||
services.nginx.virtualHosts."photos.lava.moe" = {
|
services.nginx.virtualHosts."${fqdn}" = {
|
||||||
useACMEHost = "lava.moe";
|
useACMEHost = "lava.moe";
|
||||||
forceSSL = true;
|
forceSSL = true;
|
||||||
listenAddresses = config.me.localAddrs;
|
listenAddresses = config.me.localAddrs;
|
||||||
|
|
@ -28,4 +37,20 @@
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
services.nginx.virtualHosts."${shareFqdn}" = {
|
||||||
|
useACMEHost = "lava.moe";
|
||||||
|
forceSSL = true;
|
||||||
|
|
||||||
|
locations."/" = {
|
||||||
|
proxyPass = "http://[::1]:${toString config.services.immich-public-proxy.port}";
|
||||||
|
proxyWebsockets = true;
|
||||||
|
extraConfig = ''
|
||||||
|
client_max_body_size 50000M;
|
||||||
|
proxy_read_timeout 600s;
|
||||||
|
proxy_send_timeout 600s;
|
||||||
|
send_timeout 600s;
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue