mailing test things

This commit is contained in:
catvayor 2024-07-18 14:47:43 +02:00
parent 55a54884f5
commit ce86031a00
Signed by: lbailly
GPG key ID: CE3E645251AC63F3
4 changed files with 25 additions and 4 deletions

View file

@ -6,7 +6,7 @@
... ...
}: }:
let let
host = "betamail.katvayor.net"; host = "catvayor.sh";
in in
{ {
imports = [ imports = [
@ -86,6 +86,7 @@ in
}; };
services.nginx = { services.nginx = {
enable = true; enable = true;
virtualHosts."catvayor.sh".enableACME = true;
virtualHosts."betamail.katvayor.net" = { virtualHosts."betamail.katvayor.net" = {
enableACME = true; enableACME = true;
addSSL = true; addSSL = true;
@ -98,13 +99,13 @@ in
mailserver = { mailserver = {
enable = true; enable = true;
fqdn = host; fqdn = "betamail.katvayor.net";
domains = [ host ]; domains = [ host ];
loginAccounts = { loginAccounts = {
"root@${host}" = { "root@${host}" = {
catchAll = [ host ]; catchAll = [ host ];
aliases = builtins.genList (id: "user${toString id}@${host}") 10 ++ [ "moderators@${host}" ]; aliases = builtins.genList (id: "user${toString id}@${host}") 10 ++ [ "moderators@${host}" "daemon@${host}" ];
hashedPassword = "$2b$05$FoCVDECXYG0KXPigPuIZtuNFiviwSg8RuXx0FbnzC7ZRp.Mz8VWOe"; hashedPassword = "$2b$05$FoCVDECXYG0KXPigPuIZtuNFiviwSg8RuXx0FbnzC7ZRp.Mz8VWOe";
}; };
}; };
@ -112,5 +113,7 @@ in
certificateScheme = "acme"; certificateScheme = "acme";
}; };
services.netbird.enable = true;
system.stateVersion = "23.11"; system.stateVersion = "23.11";
} }

View file

@ -5,6 +5,9 @@
lib, lib,
... ...
}: }:
let
host = "catvayor.sh";
in
{ {
users.users.moderators = { users.users.moderators = {
shell = pkgs.zsh; shell = pkgs.zsh;
@ -18,7 +21,7 @@
zsh zsh
]; ];
}; };
mailserver.loginAccounts."moderators@betamail.katvayor.net" = { mailserver.loginAccounts."moderators@${host}" = {
hashedPassword = ""; hashedPassword = "";
sieveScript = '' sieveScript = ''
require "vnd.dovecot.pipe"; require "vnd.dovecot.pipe";

View file

@ -70,6 +70,10 @@
vm = "192.168.122.3"; vm = "192.168.122.3";
sshport = 22002; sshport = 22002;
}; };
"catvayor.sh" = {
vm = "192.168.122.3";
sshport = null;
};
"traque.dgnum.eu" = { "traque.dgnum.eu" = {
vm = "192.168.122.4"; vm = "192.168.122.4";
sshport = null; sshport = null;
@ -172,12 +176,17 @@
listen 465; listen 465;
proxy_pass 192.168.122.3:465; proxy_pass 192.168.122.3:465;
} }
server {
listen 25;
proxy_pass 192.168.122.3:25;
}
''; '';
}; };
networking.firewall = { networking.firewall = {
allowedTCPPorts = [ allowedTCPPorts = [
22 22
25
53 53
80 80
443 443

View file

@ -67,6 +67,7 @@
"traque.katvayor.net" = 22001; "traque.katvayor.net" = 22001;
"traque.dgnum.eu" = null; "traque.dgnum.eu" = null;
"betamail.katvayor.net" = 22002; "betamail.katvayor.net" = 22002;
"catvayor.sh" = null;
"test.traque.katvayor.net" = null; "test.traque.katvayor.net" = null;
"son.katvayor.net" = null; "son.katvayor.net" = null;
}; };
@ -150,6 +151,10 @@
listen 465; listen 465;
proxy_pass ${kat-r86s}:465; proxy_pass ${kat-r86s}:465;
} }
server {
listen 25;
proxy_pass ${kat-r86s}:25;
}
''; '';
}; };
@ -179,6 +184,7 @@
firewall = { firewall = {
allowedTCPPorts = [ allowedTCPPorts = [
22 22
25
80 80
443 443
993 993