From be6a8e9cc7f782cd901d92ec4489a77e9b4366a6 Mon Sep 17 00:00:00 2001 From: Ingolf Wagner Date: Mon, 8 Feb 2021 20:48:44 +0100 Subject: [PATCH] mailserver setup --- configs/sputnik/mail-server.nix | 28 ++++++++++++++++++---------- 1 file changed, 18 insertions(+), 10 deletions(-) diff --git a/configs/sputnik/mail-server.nix b/configs/sputnik/mail-server.nix index 5d1d220..a272ca4 100644 --- a/configs/sputnik/mail-server.nix +++ b/configs/sputnik/mail-server.nix @@ -1,28 +1,36 @@ -{ config, pkgs, lib, ... }: { +{ config, pkgs, lib, ... }: + +# make sure no update befor changing this parameter +assert lib.versionOlder lib.version "20.09"; + +let release = "nixos-20.09"; + +in { imports = [ (builtins.fetchTarball { url = - "https://gitlab.com/simple-nixos-mailserver/nixos-mailserver/-/archive/v2.2.1/nixos-mailserver-v2.2.1.tar.gz"; - sha256 = "03d49v8qnid9g9rha0wg2z6vic06mhp0b049s3whccn1axvs2zzx"; + "https://gitlab.com/simple-nixos-mailserver/nixos-mailserver/-/archive/${release}/nixos-mailserver-${release}.tar.gz"; + # This hash needs to be updated + sha256 = "0000000000000000000000000000000000000000000000000000"; }) ]; mailserver = { enable = true; - fqdn = "mail.gaykraft.com"; - domains = [ "gaykraft.com" ]; + fqdn = "mail.ingolf-wagner.de"; + domains = [ "ingolf-wagner.de" ]; # A list of all login accounts. To create the password hashes, use # nix-shell -p mkpasswd --run 'mkpasswd -m sha-512 "super secret password"' loginAccounts = { - "root@gaykraft.com" = { + "root@ingolf-wagner.com" = { hashedPassword = lib.fileContents - ; + ; #aliases = [ # "postmaster@gaykraft.com" #]; # Make this user the catchAll address for domains - catchAll = [ "gaykraft.com" ]; + catchAll = [ "ingol-wagner.de" ]; }; }; @@ -38,9 +46,9 @@ certificateScheme = 3; # Enable IMAP and POP3 - enableImap = true; + enableImap = false; enablePop3 = true; - enableImapSsl = true; + enableImapSsl = false; enablePop3Ssl = true; # Enable the ManageSieve protocol