From 0ea52e774f54256c1948c4793c5ff298463ac22d Mon Sep 17 00:00:00 2001 From: 0xTux <0xtux@pm.me> Date: Sat, 10 Aug 2024 01:13:39 +0530 Subject: [PATCH] add ntfy-sh --- modules/nixos/ntfy-sh.nix | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 modules/nixos/ntfy-sh.nix diff --git a/modules/nixos/ntfy-sh.nix b/modules/nixos/ntfy-sh.nix new file mode 100644 index 0000000..e67a5af --- /dev/null +++ b/modules/nixos/ntfy-sh.nix @@ -0,0 +1,28 @@ +{lib, ...}: { + services = { + ntfy-sh = { + enable = true; + settings = { + listen-http = ":7070"; + base-url = "https://ntfy.tux.rs"; + behind-proxy = true; + }; + }; + + nginx = { + enable = lib.mkForce true; + virtualHosts = { + "ntfy.tux.rs" = { + forceSSL = true; + enableACME = true; + locations = { + "/" = { + proxyPass = "http://localhost:7070"; + proxyWebsockets = true; + }; + }; + }; + }; + }; + }; +}