diff --git a/parsons/mail.nix b/parsons/mail.nix index f03af06..1645885 100644 --- a/parsons/mail.nix +++ b/parsons/mail.nix @@ -1,4 +1,4 @@ -{ config, pkgs, lib, sources, ... }: +{ config, options, pkgs, lib, sources, ... }: { imports = [ sources.nixos-mailserver.outPath ]; @@ -20,6 +20,14 @@ monitoring = { enable = true; alertAddress = "admin@hacc.space"; + config = (lib.replaceStrings ["port 22"] ["port ${toString (lib.head config.services.openssh.ports)}"] options.mailserver.monitoring.config.default) + '' + check host onlyoffice with address onlyoffice.infra4future.de + if failed + port 443 + protocol https + status = 302 + then alert + ''; }; domains = [ "hacc.space"