diff options
author | tv <tv@krebsco.de> | 2020-10-03 13:44:30 +0200 |
---|---|---|
committer | tv <tv@krebsco.de> | 2020-10-03 13:44:30 +0200 |
commit | d1e52425e0d5d79a33b11c92cc2afb498075d953 (patch) | |
tree | 29277982f014eaae680e006b6afc7fdb42e8d9b2 /krebs/2configs/shack/prometheus/alertmanager-telegram.nix | |
parent | 654f64f05935a69607a540f2e8d15619cee9e15e (diff) | |
parent | 7e7499d86302d261c8f8404fb34f2ac091318d0e (diff) |
Merge remote-tracking branch 'prism/master'
Diffstat (limited to 'krebs/2configs/shack/prometheus/alertmanager-telegram.nix')
-rw-r--r-- | krebs/2configs/shack/prometheus/alertmanager-telegram.nix | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/krebs/2configs/shack/prometheus/alertmanager-telegram.nix b/krebs/2configs/shack/prometheus/alertmanager-telegram.nix new file mode 100644 index 000000000..8527001cb --- /dev/null +++ b/krebs/2configs/shack/prometheus/alertmanager-telegram.nix @@ -0,0 +1,17 @@ +{ pkgs, ...}: +{ + systemd.services.alertmanager-bot-telegram = { + wantedBy = [ "multi-user.target" ]; + after = [ "ip-up.target" ]; + serviceConfig = { + EnvironmentFile = toString <secrets/shack/telegram_bot.env>; + DynamicUser = true; + StateDirectory = "alertbot"; + ExecStart = ''${pkgs.alertmanager-bot-telegram}/bin/alertmanager-bot \ + --alertmanager.url=http://alert.prometheus.shack --log.level=info \ + --store=bolt --bolt.path=/var/lib/alertbot/bot.db \ + --listen.addr="0.0.0.0:16320" \ + --template.paths=${./templates}/shack.tmpl''; + }; + }; +} |