2020-07-03 00:02:47 +05:00
|
|
|
Quick Start
|
|
|
|
===========
|
|
|
|
|
|
|
|
.. code:: nix
|
|
|
|
|
|
|
|
{ config, pkgs, ... }:
|
2020-10-31 02:19:46 +05:00
|
|
|
let release = "nixos-20.09";
|
|
|
|
in {
|
2020-07-03 00:02:47 +05:00
|
|
|
imports = [
|
|
|
|
(builtins.fetchTarball {
|
2020-10-31 02:19:46 +05:00
|
|
|
url = "https://gitlab.com/simple-nixos-mailserver/nixos-mailserver/-/archive/${release}/nixos-mailserver-${release}.tar.gz";
|
|
|
|
# This hash needs to be updated
|
|
|
|
sha256 = "0000000000000000000000000000000000000000000000000000";
|
2020-07-03 00:02:47 +05:00
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
mailserver = {
|
|
|
|
enable = true;
|
|
|
|
fqdn = "mail.example.com";
|
|
|
|
domains = [ "example.com" "example2.com" ];
|
|
|
|
loginAccounts = {
|
|
|
|
"user1@example.com" = {
|
2020-11-29 14:58:16 +05:00
|
|
|
# nix run nixpkgs.apacheHttpd -c htpasswd -nbB "" "super secret password" | cut -d: -f2 > /hashed/password/file/location
|
2020-10-31 02:19:46 +05:00
|
|
|
hashedPasswordFile = "/hashed/password/file/location";
|
2020-07-03 00:02:47 +05:00
|
|
|
|
|
|
|
aliases = [
|
|
|
|
"info@example.com"
|
|
|
|
"postmaster@example.com"
|
|
|
|
"postmaster@example2.com"
|
|
|
|
];
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|