nix/nixos/services/ntfy.nix
2024-04-28 11:47:59 +01:00

19 lines
398 B
Nix

{ config, ... }:
let
domain = "up.${config.networking.domain}";
port = 8080;
in
{
services.ntfy-sh = {
enable = true;
settings = {
base-url = "https://${domain}";
listen-http = ":${toString port}";
};
};
services.nginx.virtualHosts.${domain} = {
forceSSL = true;
enableACME = true;
locations."~".proxyPass = "http://localhost:${toString port}";
};
}