✨ [pi4] Containerize Actual service
This commit is contained in:
@ -1,24 +1,42 @@
|
|||||||
{ config, common, ... }:
|
{ config, common, ... }:
|
||||||
let
|
let
|
||||||
cfg = config.services.actual.settings;
|
|
||||||
domain = "beta.budget.${common.domain}";
|
domain = "beta.budget.${common.domain}";
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
services = {
|
networking.nat = {
|
||||||
actual = {
|
enable = true;
|
||||||
enable = true;
|
internalInterfaces = [ "ve-*" ];
|
||||||
settings = {
|
externalInterface = "wlan0";
|
||||||
port = 8084;
|
# Lazy IPv6 connectivity for the container
|
||||||
loginMethod = "password";
|
enableIPv6 = true;
|
||||||
};
|
};
|
||||||
};
|
|
||||||
nginx.virtualHosts.${domain} = {
|
containers.actual = {
|
||||||
forceSSL = true;
|
autoStart = true;
|
||||||
enableACME = true;
|
privateNetwork = true;
|
||||||
locations."/" = {
|
hostAddress = "192.168.10.188";
|
||||||
proxyPass = "http://localhost:${toString cfg.port}";
|
localAddress = "192.168.10.11";
|
||||||
proxyWebsockets = true;
|
config =
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
services = {
|
||||||
|
actual = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
port = 8084;
|
||||||
|
loginMethod = "password";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
system.stateVersion = common.system.version;
|
||||||
};
|
};
|
||||||
|
};
|
||||||
|
services.nginx.virtualHosts.${domain} = {
|
||||||
|
forceSSL = true;
|
||||||
|
enableACME = true;
|
||||||
|
locations."/" = {
|
||||||
|
proxyPass = "http://${config.containers.actual.localAddress}:8084";
|
||||||
|
proxyWebsockets = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user