Use the same Cloudflare tunnel ID for all services
This commit is contained in:
parent
f0d272038f
commit
ec5daa9a52
4 changed files with 12 additions and 28 deletions
|
@ -6,6 +6,11 @@ with lib;
|
|||
options.homelab = {
|
||||
enable = mkEnableOption "Enable homelab services and configuration";
|
||||
|
||||
cloudflared.tunnelId = mkOption {
|
||||
example = "00000000-0000-0000-0000-000000000000";
|
||||
type = types.str;
|
||||
};
|
||||
|
||||
domain = mkOption {
|
||||
description = "The base domain to use for this homelab.";
|
||||
type = types.str;
|
||||
|
|
|
@ -16,11 +16,6 @@ in
|
|||
type = types.str;
|
||||
};
|
||||
|
||||
cloudflared.tunnelId = mkOption {
|
||||
example = "00000000-0000-0000-0000-000000000000";
|
||||
type = types.str;
|
||||
};
|
||||
|
||||
homepage.name = mkOption {
|
||||
default = "Forgejo";
|
||||
type = types.str;
|
||||
|
@ -58,7 +53,7 @@ in
|
|||
};
|
||||
};
|
||||
|
||||
cloudflared.tunnels.${cfg.cloudflared.tunnelId}.ingress = {
|
||||
cloudflared.tunnels.${homelab.cloudflared.tunnelId}.ingress = {
|
||||
${cfg.url} = "http://localhost:${toString config.services.${service}.settings.server.HTTP_PORT}";
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue