Compare commits
1 Commits
82b8c41cff
...
router/kee
Author | SHA1 | Date | |
---|---|---|---|
b06982a443
|
12
flake.lock
generated
12
flake.lock
generated
@@ -7,11 +7,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1750650909,
|
"lastModified": 1749178927,
|
||||||
"narHash": "sha256-HRNJuqo15PRKezyBjhNf2Tjj05EcSJ8q6xJyDDbmDXE=",
|
"narHash": "sha256-bXcEx1aZUNm5hMLVJeuofcOrZyOiapzvQ7K36HYK3YQ=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "520fc4b50af1b365014c3748c126d3f52edb2f3b",
|
"rev": "91287a0e9d42570754487b7e38c6697e15a9aab2",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -58,11 +58,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1750506804,
|
"lastModified": 1748929857,
|
||||||
"narHash": "sha256-VLFNc4egNjovYVxDGyBYTrvVCgDYgENp5bVi9fPTDYc=",
|
"narHash": "sha256-lcZQ8RhsmhsK8u7LIFsJhsLh/pzR9yZ8yqpTzyGdj+Q=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "4206c4cb56751df534751b058295ea61357bbbaa",
|
"rev": "c2a03962b8e24e669fb37b7df10e7c79531ff1a4",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@@ -14,6 +14,7 @@ in
|
|||||||
./kea.nix
|
./kea.nix
|
||||||
./glance.nix
|
./glance.nix
|
||||||
./services.nix
|
./services.nix
|
||||||
|
./keepalived.nix
|
||||||
];
|
];
|
||||||
# Secrix for secrets management
|
# Secrix for secrets management
|
||||||
secrix.hostPubKey = vars.pubkey;
|
secrix.hostPubKey = vars.pubkey;
|
||||||
|
@@ -80,8 +80,6 @@ in
|
|||||||
"|etappi.${sysdomain}^$dnsrewrite=${ifs.lan.p4}.12"
|
"|etappi.${sysdomain}^$dnsrewrite=${ifs.lan.p4}.12"
|
||||||
"|etappi.${sysdomain}^$dnsrewrite=${ifs.lan.ulaPrefix}::12:1"
|
"|etappi.${sysdomain}^$dnsrewrite=${ifs.lan.ulaPrefix}::12:1"
|
||||||
|
|
||||||
"|hass.${domain}^$dnsrewrite=${ifs.lan.ulaAddr}"
|
|
||||||
|
|
||||||
# Lab DNS rewrites
|
# Lab DNS rewrites
|
||||||
"||lab.${domain}^$dnsrewrite=etappi.${sysdomain}"
|
"||lab.${domain}^$dnsrewrite=etappi.${sysdomain}"
|
||||||
|
|
||||||
|
10
modules/router/keepalived.nix
Normal file
10
modules/router/keepalived.nix
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
let
|
||||||
|
vaks = import ./vaks.nix config;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
services.keepalived = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
};
|
||||||
|
}
|
@@ -60,15 +60,12 @@ in
|
|||||||
plugins = [ "github.com/caddy-dns/cloudflare@v0.2.1" ];
|
plugins = [ "github.com/caddy-dns/cloudflare@v0.2.1" ];
|
||||||
hash = "sha256-Gsuo+ripJSgKSYOM9/yl6Kt/6BFCA6BuTDvPdteinAI=";
|
hash = "sha256-Gsuo+ripJSgKSYOM9/yl6Kt/6BFCA6BuTDvPdteinAI=";
|
||||||
};
|
};
|
||||||
virtualHosts."*.${domain}".extraConfig = ''
|
virtualHosts."grouter.${domain}".extraConfig = ''
|
||||||
encode
|
encode
|
||||||
tls {
|
tls {
|
||||||
dns cloudflare {env.CF_API_KEY}
|
dns cloudflare {env.CF_API_KEY}
|
||||||
resolvers 1.1.1.1
|
resolvers 1.1.1.1
|
||||||
}
|
}
|
||||||
|
|
||||||
@grouter host grouter.${domain}
|
|
||||||
handle @grouter {
|
|
||||||
@grafana path /grafana /grafana/*
|
@grafana path /grafana /grafana/*
|
||||||
handle @grafana {
|
handle @grafana {
|
||||||
reverse_proxy localhost:${toString config.services.grafana.settings.server.http_port}
|
reverse_proxy localhost:${toString config.services.grafana.settings.server.http_port}
|
||||||
@@ -83,12 +80,6 @@ in
|
|||||||
handle /* {
|
handle /* {
|
||||||
reverse_proxy localhost:${toString config.services.glance.settings.server.port}
|
reverse_proxy localhost:${toString config.services.glance.settings.server.port}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
@hass host hass.${domain}
|
|
||||||
handle @hass {
|
|
||||||
reverse_proxy homeassistant.4.lab.l.cazzzer.com:8123
|
|
||||||
}
|
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user