nixos/home/services/natstonotify.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

22 lines
535 B
Nix
Raw Normal View History

2025-02-11 19:48:34 +00:00
{ pkgs, config, ... }:
2025-02-11 19:14:37 +00:00
{
2025-02-11 19:48:34 +00:00
sops.secrets."nats_nkey" = { };
2025-02-11 19:14:37 +00:00
systemd.user.services.natstonotify = {
Unit = {
Description = "Run natstonotify";
2025-02-11 19:48:34 +00:00
After = [ "sops-nix.service" ];
2025-02-11 19:14:37 +00:00
};
Service = {
2025-02-11 19:48:34 +00:00
Environment = [
"NATS_URL=nats://nats1.home.2rjus.net:4222"
"NATS_NKEY_FILE=${config.sops.secrets.nats_nkey.path}"
];
2025-02-11 19:14:37 +00:00
Type = "simple";
2025-02-11 19:48:34 +00:00
ExecStart = "${pkgs.natstonotify}/bin/natstonotify server";
2025-02-11 19:14:37 +00:00
};
Install = {
WantedBy = [ "graphical-session.target" ];
};
};
}