2 Commits

Author SHA1 Message Date
Danilo Reyes
ee11d72de8 domain sandbox 2026-02-05 04:16:21 -06:00
Danilo Reyes
dce2142794 proper ip assignation for nginx 2026-02-05 03:39:27 -06:00
5 changed files with 12 additions and 17 deletions

View File

@@ -3,12 +3,13 @@ let
inherit (inputs.self.lib)
enableList
mkEnabled
mkEnabledProxy
mkEnabledWithUsers
;
mkEnabledProxyIp = inputs.self.lib.mkEnabledProxyIp config.my.ips.wg-server;
wgServerIp = config.my.ips.wg-server;
mkEnabledProxyIp = inputs.self.lib.mkEnabledProxyIp wgServerIp;
in
{
domain = "servidos.lat";
enableProxy = true;
enableContainers = true;
apps.dictionaries.enable = true;
@@ -33,9 +34,11 @@ in
};
nextcloud = {
enableProxy = true;
ip = wgServerIp;
port = 8081;
};
}
// enableList mkEnabledProxy [
// enableList mkEnabledProxyIp [
"bazarr"
"collabora"
"gitea"
@@ -53,8 +56,6 @@ in
"radarr"
"sonarr"
"yamtrack"
]
// enableList mkEnabledProxyIp [
"audiobookshelf"
"isso"
"keycloak"

View File

@@ -74,7 +74,7 @@ in
};
mainServer = lib.mkOption {
type = lib.types.str;
default = "vps";
default = "server";
description = "The hostname of the main server.";
};
postgresSocket = lib.mkOption {

View File

@@ -167,7 +167,7 @@ in
forceSSL = false; # vps
enableACME = false; # vps
http2 = false; # vps
# default = true; #vps
default = true; # vps
#vps
listen = [
{
@@ -261,7 +261,7 @@ in
collabora = lib.mkIf cfgC.enable {
autoStart = true;
image = "collabora/code:latest";
ports = [ "9980:9980" ];
ports = [ "${toString cfgC.port}:${toString cfgC.port}" ];
environment = {
TZ = config.my.timeZone;
domain = cfg.host;

View File

@@ -40,7 +40,7 @@ in
secure = true;
expire = "168h";
refresh = "1h";
domain = ".lebubu.org";
domain = ".${config.my.domain}";
secret = config.sops.secrets.oauth2-proxy-cookie.path;
};
extraConfig = {
@@ -53,7 +53,7 @@ in
session-store-type = "cookie";
skip-provider-button = true;
code-challenge-method = "S256";
whitelist-domain = [ ".lebubu.org" ];
whitelist-domain = [ ".${config.my.domain}" ];
};
};
};

View File

@@ -196,16 +196,10 @@ in
inherit ip;
};
};
mkEnabledProxy = name: {
inherit name;
value = {
enableProxy = true;
};
};
mkEnabledProxyIp = ip: name: {
inherit name;
value = {
enable = true;
enableProxy = true;
inherit ip;
};
};