mirror of
https://github.com/JulienMalka/snowfield.git
synced 2025-06-08 10:09:04 +02:00
feat(lambda): init stateless uptime-kuma
This commit is contained in:
parent
06fe1c0cb2
commit
a78b000356
6 changed files with 76 additions and 28 deletions
|
@ -10,6 +10,7 @@
|
|||
./hardware.nix
|
||||
./home-julien.nix
|
||||
./arkheon.nix
|
||||
./uptime-kuma.nix
|
||||
];
|
||||
|
||||
machine.meta = {
|
||||
|
@ -41,14 +42,6 @@
|
|||
|
||||
luj.nginx.enable = true;
|
||||
|
||||
services.uptime-kuma = {
|
||||
enable = true;
|
||||
package = pkgs.unstable.uptime-kuma;
|
||||
settings = {
|
||||
NODE_EXTRA_CA_CERTS = "/etc/ssl/certs/ca-certificates.crt";
|
||||
};
|
||||
};
|
||||
|
||||
services.ntfy-sh = {
|
||||
enable = true;
|
||||
package = pkgs.unstable.ntfy-sh;
|
||||
|
@ -62,26 +55,6 @@
|
|||
};
|
||||
};
|
||||
|
||||
services.nginx.virtualHosts."status.julienmalka.me" = {
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
locations."/" = {
|
||||
proxyPass = "http://localhost:3001";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
};
|
||||
|
||||
security.acme.certs."uptime.luj".server = "https://ca.luj/acme/acme/directory";
|
||||
|
||||
services.nginx.virtualHosts."uptime.luj" = {
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
locations."/" = {
|
||||
proxyPass = "http://localhost:3001";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
};
|
||||
|
||||
services.nginx.virtualHosts."notifications.julienmalka.me" = {
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
|
|
47
machines/lambda/uptime-kuma.nix
Normal file
47
machines/lambda/uptime-kuma.nix
Normal file
|
@ -0,0 +1,47 @@
|
|||
{ pkgs, config, ... }:
|
||||
{
|
||||
|
||||
services.uptime-kuma = {
|
||||
enable = true;
|
||||
package = pkgs.unstable.uptime-kuma;
|
||||
settings = {
|
||||
NODE_EXTRA_CA_CERTS = "/etc/ssl/certs/ca-certificates.crt";
|
||||
};
|
||||
};
|
||||
|
||||
services.nginx.virtualHosts."status.julienmalka.me" = {
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
locations."/" = {
|
||||
proxyPass = "http://localhost:3001";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
};
|
||||
|
||||
age.secrets."stateless-uptime-kuma-password".file = ../../secrets/stateless-uptime-kuma-password.age;
|
||||
statelessUptimeKuma = {
|
||||
enableService = true;
|
||||
probesConfig = {
|
||||
monitors = {
|
||||
"mdr" = {
|
||||
url = "https://82.67.34.230";
|
||||
keyword = "Ulm";
|
||||
type = "keyword";
|
||||
accepted_statuscodes = [ "200-299" ];
|
||||
headers = ''
|
||||
{
|
||||
"Host": "julienmalka.me"
|
||||
}
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
extraFlags = [ "-s" ];
|
||||
|
||||
host = "http://localhost:${builtins.toString 3001}/";
|
||||
username = "Julien";
|
||||
passwordFile = config.age.secrets."stateless-uptime-kuma-password".path;
|
||||
};
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue