mirror of
https://github.com/rubenhensen/k8scd.git
synced 2026-09-17 02:12:55 +02:00
Move to simpler email setup
This commit is contained in:
@@ -7,10 +7,6 @@ records:
|
|||||||
expire: 300
|
expire: 300
|
||||||
type: A
|
type: A
|
||||||
content: "46.224.26.65"
|
content: "46.224.26.65"
|
||||||
- name: stalwart
|
|
||||||
expire: 300
|
|
||||||
type: A
|
|
||||||
content: "46.224.26.65"
|
|
||||||
- name: "phocaslustrum"
|
- name: "phocaslustrum"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: A
|
type: A
|
||||||
@@ -58,7 +54,7 @@ records:
|
|||||||
- name: "@"
|
- name: "@"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: MX
|
type: MX
|
||||||
content: "10 stalwart.rubenhensen.nl."
|
content: "10 mail.rubenhensen.nl."
|
||||||
- name: "202603e._domainkey"
|
- name: "202603e._domainkey"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: TXT
|
type: TXT
|
||||||
@@ -75,7 +71,7 @@ records:
|
|||||||
expire: 300
|
expire: 300
|
||||||
type: TXT
|
type: TXT
|
||||||
content: "v=DKIM1; k=rsa; h=sha256; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEApBm+QIOPtVAWlnpcd1Sh/FjTLU4oXNdyYMZ4uo+uj+8PkewhzN+6gb9CD/M6NB8Wa+8kchcVlziB1GD4z07QAAJg8pGSs1UZ7Ggfp7RgE6CkiPvMxAE6PkP9mBKcPH9YFR0xQaoi0BHQD1EKmPq2vXOc3BFtgkoeO+Myo6ELenpf17Iv6PcBxyLBOBnnFB4Uhos8qJ8qHb+hHhL6wR8sxk+OAPLXDWVRtrTXvOrlDoRBjz9X0xKdyE3aOQ6xg+qHusVIszLFz8iO6L5ia/rtwnm9v92NR9g0r3/lJE3AJFYqKIF7kPcdjyowvuUjlpDQedXSaEkytGzc84JbkHE+jQIDAQAB"
|
content: "v=DKIM1; k=rsa; h=sha256; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEApBm+QIOPtVAWlnpcd1Sh/FjTLU4oXNdyYMZ4uo+uj+8PkewhzN+6gb9CD/M6NB8Wa+8kchcVlziB1GD4z07QAAJg8pGSs1UZ7Ggfp7RgE6CkiPvMxAE6PkP9mBKcPH9YFR0xQaoi0BHQD1EKmPq2vXOc3BFtgkoeO+Myo6ELenpf17Iv6PcBxyLBOBnnFB4Uhos8qJ8qHb+hHhL6wR8sxk+OAPLXDWVRtrTXvOrlDoRBjz9X0xKdyE3aOQ6xg+qHusVIszLFz8iO6L5ia/rtwnm9v92NR9g0r3/lJE3AJFYqKIF7kPcdjyowvuUjlpDQedXSaEkytGzc84JbkHE+jQIDAQAB"
|
||||||
- name: stalwart
|
- name: mail
|
||||||
expire: 300
|
expire: 300
|
||||||
type: TXT
|
type: TXT
|
||||||
content: "v=spf1 a ra=postmaster -all"
|
content: "v=spf1 a ra=postmaster -all"
|
||||||
@@ -86,39 +82,39 @@ records:
|
|||||||
- name: "_jmap._tcp"
|
- name: "_jmap._tcp"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: SRV
|
type: SRV
|
||||||
content: "0 1 443 stalwart.rubenhensen.nl."
|
content: "0 1 443 mail.rubenhensen.nl."
|
||||||
- name: "_caldavs._tcp"
|
- name: "_caldavs._tcp"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: SRV
|
type: SRV
|
||||||
content: "0 1 443 stalwart.rubenhensen.nl."
|
content: "0 1 443 mail.rubenhensen.nl."
|
||||||
- name: "_carddavs._tcp"
|
- name: "_carddavs._tcp"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: SRV
|
type: SRV
|
||||||
content: "0 1 443 stalwart.rubenhensen.nl."
|
content: "0 1 443 mail.rubenhensen.nl."
|
||||||
- name: "_imaps._tcp"
|
- name: "_imaps._tcp"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: SRV
|
type: SRV
|
||||||
content: "0 1 993 stalwart.rubenhensen.nl."
|
content: "0 1 993 mail.rubenhensen.nl."
|
||||||
- name: "_submissions._tcp"
|
- name: "_submissions._tcp"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: SRV
|
type: SRV
|
||||||
content: "0 1 465 stalwart.rubenhensen.nl."
|
content: "0 1 465 mail.rubenhensen.nl."
|
||||||
- name: "_submission._tcp"
|
- name: "_submission._tcp"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: SRV
|
type: SRV
|
||||||
content: "0 1 587 stalwart.rubenhensen.nl."
|
content: "0 1 587 mail.rubenhensen.nl."
|
||||||
- name: autoconfig
|
- name: autoconfig
|
||||||
expire: 300
|
expire: 300
|
||||||
type: CNAME
|
type: CNAME
|
||||||
content: "stalwart.rubenhensen.nl."
|
content: "mail.rubenhensen.nl."
|
||||||
- name: autodiscover
|
- name: autodiscover
|
||||||
expire: 300
|
expire: 300
|
||||||
type: CNAME
|
type: CNAME
|
||||||
content: "stalwart.rubenhensen.nl."
|
content: "mail.rubenhensen.nl."
|
||||||
- name: mta-sts
|
- name: mta-sts
|
||||||
expire: 300
|
expire: 300
|
||||||
type: CNAME
|
type: CNAME
|
||||||
content: "stalwart.rubenhensen.nl."
|
content: "mail.rubenhensen.nl."
|
||||||
- name: "_mta-sts"
|
- name: "_mta-sts"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: TXT
|
type: TXT
|
||||||
@@ -131,35 +127,35 @@ records:
|
|||||||
expire: 300
|
expire: 300
|
||||||
type: TXT
|
type: TXT
|
||||||
content: "v=TLSRPTv1; rua=mailto:postmaster@rubenhensen.nl"
|
content: "v=TLSRPTv1; rua=mailto:postmaster@rubenhensen.nl"
|
||||||
- name: "_25._tcp.stalwart"
|
- name: "_25._tcp.mail"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: TLSA
|
type: TLSA
|
||||||
content: "3 0 1 7926a9616cea1a7fb851fbdab631b2b2f6f71d3a775178d3288e539b9f53b18d"
|
content: "3 0 1 7926a9616cea1a7fb851fbdab631b2b2f6f71d3a775178d3288e539b9f53b18d"
|
||||||
- name: "_25._tcp.stalwart"
|
- name: "_25._tcp.mail"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: TLSA
|
type: TLSA
|
||||||
content: "3 0 2 2218e33f102e805841f2f6a368e6416d884a8658cd9f45ef9b28c233dc6803320cff976e8ffdb1c0603a7abe60ccf78de422c31753b6cece8bc7ec1b80de5b66"
|
content: "3 0 2 2218e33f102e805841f2f6a368e6416d884a8658cd9f45ef9b28c233dc6803320cff976e8ffdb1c0603a7abe60ccf78de422c31753b6cece8bc7ec1b80de5b66"
|
||||||
- name: "_25._tcp.stalwart"
|
- name: "_25._tcp.mail"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: TLSA
|
type: TLSA
|
||||||
content: "3 1 1 e473431a9f296a8d93dfbed7c6c9485d6dadf7b460879edc0fe905183fe78a41"
|
content: "3 1 1 e473431a9f296a8d93dfbed7c6c9485d6dadf7b460879edc0fe905183fe78a41"
|
||||||
- name: "_25._tcp.stalwart"
|
- name: "_25._tcp.mail"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: TLSA
|
type: TLSA
|
||||||
content: "3 1 2 4c6cdab2a9cad307ba5b77ef34bde0cc2846b3d27aef6ce9625c56ef11b5c9cd1ede662c3afa759a3190e6317df494564ac83e4bfe3e6467f3c1bf307d781d4a"
|
content: "3 1 2 4c6cdab2a9cad307ba5b77ef34bde0cc2846b3d27aef6ce9625c56ef11b5c9cd1ede662c3afa759a3190e6317df494564ac83e4bfe3e6467f3c1bf307d781d4a"
|
||||||
- name: "_25._tcp.stalwart"
|
- name: "_25._tcp.mail"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: TLSA
|
type: TLSA
|
||||||
content: "2 0 1 aeb1fd7410e83bc96f5da3c6a7c2c1bb836d1fa5cb86e708515890e428a8770b"
|
content: "2 0 1 aeb1fd7410e83bc96f5da3c6a7c2c1bb836d1fa5cb86e708515890e428a8770b"
|
||||||
- name: "_25._tcp.stalwart"
|
- name: "_25._tcp.mail"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: TLSA
|
type: TLSA
|
||||||
content: "2 0 2 e18f3d6ccbc578f025c3c7c29ed7bffe1b8eef5b1f839c17298dcf218303d2a63e305f6c1f489691774a18bad836035e5af2de1fc42a3a26cfe9e530f92e3855"
|
content: "2 0 2 e18f3d6ccbc578f025c3c7c29ed7bffe1b8eef5b1f839c17298dcf218303d2a63e305f6c1f489691774a18bad836035e5af2de1fc42a3a26cfe9e530f92e3855"
|
||||||
- name: "_25._tcp.stalwart"
|
- name: "_25._tcp.mail"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: TLSA
|
type: TLSA
|
||||||
content: "2 1 1 cbbc559b44d524d6a132bdac672744da3407f12aae5d5f722c5f6c7913871c75"
|
content: "2 1 1 cbbc559b44d524d6a132bdac672744da3407f12aae5d5f722c5f6c7913871c75"
|
||||||
- name: "_25._tcp.stalwart"
|
- name: "_25._tcp.mail"
|
||||||
expire: 300
|
expire: 300
|
||||||
type: TLSA
|
type: TLSA
|
||||||
content: "2 1 2 7d779dd26d37ca5a72fd05f1b815a06078c8e09777697c651fbe012c8d2894e048fcfe24160ee1562602240b6bef44e00f2b7340c84546d6110842bbdeb484a7"
|
content: "2 1 2 7d779dd26d37ca5a72fd05f1b815a06078c8e09777697c651fbe012c8d2894e048fcfe24160ee1562602240b6bef44e00f2b7340c84546d6110842bbdeb484a7"
|
||||||
|
|||||||
@@ -19,7 +19,7 @@
|
|||||||
security.acme = {
|
security.acme = {
|
||||||
acceptTerms = true;
|
acceptTerms = true;
|
||||||
defaults.email = "admin@rubenhensen.nl";
|
defaults.email = "admin@rubenhensen.nl";
|
||||||
certs."stalwart.rubenhensen.nl" = {
|
certs."mail.rubenhensen.nl" = {
|
||||||
group = "stalwart-mail";
|
group = "stalwart-mail";
|
||||||
reloadServices = [ "stalwart-mail" ];
|
reloadServices = [ "stalwart-mail" ];
|
||||||
webroot = "/var/lib/acme/acme-challenge";
|
webroot = "/var/lib/acme/acme-challenge";
|
||||||
@@ -38,7 +38,7 @@
|
|||||||
# Serve ACME challenges via nginx on port 80
|
# Serve ACME challenges via nginx on port 80
|
||||||
services.nginx = {
|
services.nginx = {
|
||||||
enable = true;
|
enable = true;
|
||||||
virtualHosts."stalwart.rubenhensen.nl" = {
|
virtualHosts."mail.rubenhensen.nl" = {
|
||||||
listen = [
|
listen = [
|
||||||
{ addr = "0.0.0.0"; port = 80; }
|
{ addr = "0.0.0.0"; port = 80; }
|
||||||
{ addr = "[::]"; port = 80; }
|
{ addr = "[::]"; port = 80; }
|
||||||
@@ -95,7 +95,7 @@
|
|||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
server = {
|
server = {
|
||||||
hostname = "stalwart.rubenhensen.nl";
|
hostname = "mail.rubenhensen.nl";
|
||||||
listener = {
|
listener = {
|
||||||
smtp = {
|
smtp = {
|
||||||
bind = "[::]:25";
|
bind = "[::]:25";
|
||||||
@@ -128,8 +128,8 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
certificate.default = {
|
certificate.default = {
|
||||||
cert = "%{file:/var/lib/acme/stalwart.rubenhensen.nl/fullchain.pem}%";
|
cert = "%{file:/var/lib/acme/mail.rubenhensen.nl/fullchain.pem}%";
|
||||||
private-key = "%{file:/var/lib/acme/stalwart.rubenhensen.nl/key.pem}%";
|
private-key = "%{file:/var/lib/acme/mail.rubenhensen.nl/key.pem}%";
|
||||||
};
|
};
|
||||||
|
|
||||||
storage = {
|
storage = {
|
||||||
@@ -137,7 +137,7 @@
|
|||||||
fts = "rocksdb";
|
fts = "rocksdb";
|
||||||
blob = "rocksdb";
|
blob = "rocksdb";
|
||||||
lookup = "rocksdb";
|
lookup = "rocksdb";
|
||||||
directory = "authentik";
|
directory = "internal";
|
||||||
};
|
};
|
||||||
|
|
||||||
store.rocksdb = {
|
store.rocksdb = {
|
||||||
@@ -158,29 +158,10 @@
|
|||||||
enable = true;
|
enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
directory.authentik = {
|
oauth.oidc = {
|
||||||
type = "ldap";
|
issuer-url = "https://authentik.rubenhensen.nl/application/o/stalwart/";
|
||||||
url = "ldap://ldap.rubenhensen.nl:389";
|
client-id = "%{file:/run/credentials/stalwart-mail.service/oidc-client-id}%";
|
||||||
timeout = "30s";
|
client-secret = "%{file:/run/credentials/stalwart-mail.service/oidc-client-secret}%";
|
||||||
tls.enable = false;
|
|
||||||
base-dn = "DC=ldap,DC=goauthentik,DC=io";
|
|
||||||
|
|
||||||
bind.dn = "cn=ldapservice,ou=users,DC=ldap,DC=goauthentik,DC=io";
|
|
||||||
bind.secret = "%{file:/run/credentials/stalwart-mail.service/ldap_bind_password}%";
|
|
||||||
bind.auth.method = "lookup";
|
|
||||||
|
|
||||||
filter = {
|
|
||||||
name = "(&(objectClass=user)(|(cn=?)(mail=?)(mailAliases=?)))";
|
|
||||||
email = "(&(objectClass=user)(|(mail=?)(mailAliases=?)))";
|
|
||||||
};
|
|
||||||
|
|
||||||
attributes = {
|
|
||||||
name = "cn";
|
|
||||||
class = "objectClass";
|
|
||||||
email = "mail";
|
|
||||||
email-alias = "mailAliases";
|
|
||||||
groups = "memberOf";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
signature."rsa" = {
|
signature."rsa" = {
|
||||||
@@ -220,7 +201,8 @@
|
|||||||
|
|
||||||
systemd.services.stalwart-mail.serviceConfig.LoadCredentialEncrypted = [
|
systemd.services.stalwart-mail.serviceConfig.LoadCredentialEncrypted = [
|
||||||
"stalwart-admin-password:/root/secrets/[%%secrets/stalwart-admin-password%%]"
|
"stalwart-admin-password:/root/secrets/[%%secrets/stalwart-admin-password%%]"
|
||||||
"ldap_bind_password:/root/secrets/[%%secrets/ldap_bind_password%%]"
|
"oidc-client-id:/root/secrets/[%%secrets/oidc-client-id%%]"
|
||||||
|
"oidc-client-secret:/root/secrets/[%%secrets/oidc-client-secret%%]"
|
||||||
"dkim-rsa.key:/root/secrets/[%%secrets/dkim-rsa.key%%]"
|
"dkim-rsa.key:/root/secrets/[%%secrets/dkim-rsa.key%%]"
|
||||||
"dkim-ed25519.key:/root/secrets/[%%secrets/dkim-ed25519.key%%]"
|
"dkim-ed25519.key:/root/secrets/[%%secrets/dkim-ed25519.key%%]"
|
||||||
];
|
];
|
||||||
|
|||||||
Reference in New Issue
Block a user