Add ntfy ssh login alerts. Include systemd service logs with service errors
All checks were successful
Check Flake / check-flake (push) Successful in 3m34s
All checks were successful
Check Flake / check-flake (push) Successful in 3m34s
This commit is contained in:
27
common/ntfy/default.nix
Normal file
27
common/ntfy/default.nix
Normal file
@@ -0,0 +1,27 @@
|
||||
{ config, lib, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./service-failure.nix
|
||||
./ssh-login.nix
|
||||
./zfs.nix
|
||||
];
|
||||
|
||||
options.ntfy-alerts = {
|
||||
serverUrl = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "https://ntfy.neet.dev";
|
||||
description = "Base URL of the ntfy server.";
|
||||
};
|
||||
|
||||
curlExtraArgs = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "";
|
||||
description = "Extra arguments to pass to curl (e.g. --proxy http://host:port).";
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.thisMachine.hasRole."ntfy" {
|
||||
age.secrets.ntfy-token.file = ../../secrets/ntfy-token.age;
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user