From ea428faf99f1ab3ca69718aba1041838bb983b3b Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Sat, 11 Jul 2020 12:51:04 +0100 Subject: feat(whitby): Enable smtprelay module This is required for the Gerrit setup. Change-Id: I02e03dafe36e6c47ffabf4d590e0c6f1dea027e6 Reviewed-on: https://cl.tvl.fyi/c/depot/+/1061 Tested-by: BuildkiteCI Reviewed-by: lukegb --- ops/nixos/whitby/default.nix | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) (limited to 'ops/nixos/whitby') diff --git a/ops/nixos/whitby/default.nix b/ops/nixos/whitby/default.nix index e909f4d1f661..38a9f9a55062 100644 --- a/ops/nixos/whitby/default.nix +++ b/ops/nixos/whitby/default.nix @@ -16,9 +16,10 @@ in { inherit depot; imports = [ "${depot.depotPath}/ops/nixos/depot.nix" + "${depot.depotPath}/ops/nixos/smtprelay.nix" "${depot.depotPath}/ops/nixos/tvl-slapd/default.nix" - "${depot.depotPath}/ops/nixos/www/login.tvl.fyi.nix" "${depot.depotPath}/ops/nixos/tvl-sso/default.nix" + "${depot.depotPath}/ops/nixos/www/login.tvl.fyi.nix" ]; hardware = { @@ -152,6 +153,17 @@ in { }; }) (range 1 8)); + # Start a local SMTP relay to Gmail (used by gerrit) + services.depot.smtprelay = { + enable = true; + args = { + listen = ":2525"; + remote_host = "smtp.gmail.com:587"; + remote_auth = "plain"; + remote_user = "tvlbot@tazj.in"; + }; + }; + environment.systemPackages = with nixpkgs; [ bb curl -- cgit 1.4.1