test
This commit is contained in:
@@ -12,7 +12,7 @@ let
|
||||
hostAddress = "10.0.1.3";
|
||||
actualUserId = config.users.users.nix-apps.uid;
|
||||
actualGroupId = config.users.groups.jallen-nas.gid;
|
||||
|
||||
|
||||
actualConfig =
|
||||
{ lib, ... }:
|
||||
{
|
||||
@@ -80,12 +80,12 @@ let
|
||||
system.stateVersion = "23.11";
|
||||
};
|
||||
|
||||
bindMounts = {
|
||||
${dataDir} = {
|
||||
hostPath = cfg.dataDir;
|
||||
isReadOnly = false;
|
||||
};
|
||||
bindMounts = {
|
||||
${dataDir} = {
|
||||
hostPath = cfg.dataDir;
|
||||
isReadOnly = false;
|
||||
};
|
||||
};
|
||||
|
||||
# Create reverse proxy configuration using mkReverseProxy
|
||||
reverseProxyConfig = lib.${namespace}.mkReverseProxy {
|
||||
@@ -95,23 +95,25 @@ let
|
||||
middlewares = cfg.reverseProxy.middlewares;
|
||||
};
|
||||
|
||||
actualContainer = (lib.${namespace}.mkContainer {
|
||||
name = "actual";
|
||||
localAddress = cfg.localAddress;
|
||||
port = cfg.port;
|
||||
bindMounts = bindMounts;
|
||||
config = actualConfig;
|
||||
}) { inherit lib; };
|
||||
actualContainer =
|
||||
(lib.${namespace}.mkContainer {
|
||||
name = "actual";
|
||||
localAddress = cfg.localAddress;
|
||||
port = cfg.port;
|
||||
bindMounts = bindMounts;
|
||||
config = actualConfig;
|
||||
})
|
||||
{ inherit lib; };
|
||||
|
||||
fullConfig = {
|
||||
${namespace}.services.traefik = lib.mkIf cfg.reverseProxy.enable {
|
||||
reverseProxies = [ reverseProxyConfig ];
|
||||
};
|
||||
} // actualContainer;
|
||||
}
|
||||
// actualContainer;
|
||||
in
|
||||
{
|
||||
imports = [ ./options.nix ];
|
||||
|
||||
|
||||
config = mkIf cfg.enable fullConfig;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user