Files
infrastructure/machines/durruti/host_config.nix
kalipso d8d910f5fd
All checks were successful
Evaluate Hydra Jobs / eval-hydra-jobs (push) Successful in 4m7s
[uptimekuma] mv from fanny to hetzner server
after thinking about it it makes no sense to have status/alerting
running on fanny. as soon as fanny fails we wont get any alerts anymore.
thats why i think having it running on the hetzner server, which is
quite stable, makes sense
2025-01-17 14:19:38 +01:00

69 lines
1.4 KiB
Nix

{ config, lib, options, pkgs, ... }:
with lib;
let
cfg = config.services.malobeo;
in
{
options = {
services.malobeo = {
enable = mkOption {
default = false;
type = types.bool;
description = lib.mdDoc "Enable malobeo infrastructure.";
};
host_ip = mkOption {
type = types.str;
default = "";
description = lib.mdDoc "ip of nix container provided for malo";
};
};
};
config = mkIf cfg.enable
{
assertions = [
{
assertion = cfg.host_ip != "";
message = ''
You need to specify host_ip of the nix container
'';
}
];
services.nginx.virtualHosts."docs.malobeo.org" = {
forceSSL = true;
enableACME= true;
locations."/" = {
proxyPass = "http://10.0.0.10";
extraConfig = ''
'';
};
};
services.nginx.virtualHosts."status.malobeo.org" = {
forceSSL = true;
enableACME= true;
locations."/" = {
proxyPass = "http://10.0.0.12";
extraConfig = ''
'';
};
};
services.nginx.virtualHosts."tasklist.malobeo.org" = {
forceSSL = true;
enableACME= true;
locations."/".proxyPass = "http://${cfg.host_ip}:8080";
};
services.nginx.virtualHosts."booking.dynamicdiscord.de" = {
forceSSL = true;
enableACME= true;
locations."/".proxyPass = "http://${cfg.host_ip}:80";
};
};
}