alpine: add ntfy

This commit is contained in:
Tristan 2024-04-28 11:47:59 +01:00
parent 140a50310e
commit c1d50bba47
3 changed files with 20 additions and 8 deletions

View file

@ -71,6 +71,7 @@
./nixos/services/mautrix/whatsapp.nix ./nixos/services/mautrix/whatsapp.nix
./nixos/services/mautrix/signal.nix ./nixos/services/mautrix/signal.nix
./nixos/services/nextcloud.nix ./nixos/services/nextcloud.nix
./nixos/services/ntfy.nix
] []; ] [];
vm-sway = vm-sway =

View file

@ -140,14 +140,6 @@ in {
enableACME = true; enableACME = true;
root = "/srv/www/tristans.cloud"; root = "/srv/www/tristans.cloud";
}; };
"*.thebeanbakery.xyz" = {
globalRedirect = "thebeanbakery.xyz";
};
"thebeanbakery.xyz" = {
forceSSL = true;
enableACME = true;
root = "/srv/www/thebeanbakery.xyz";
};
"auth.tristans.cloud" = { "auth.tristans.cloud" = {
forceSSL = true; forceSSL = true;
enableACME = true; enableACME = true;

19
nixos/services/ntfy.nix Normal file
View file

@ -0,0 +1,19 @@
{ 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}";
};
}