mirror of
https://github.com/JulienMalka/snowfield.git
synced 2025-03-31 17:20:53 +02:00
chore: drop mailserver module
This commit is contained in:
parent
15a5e616c5
commit
05062b47ce
2 changed files with 0 additions and 108 deletions
|
@ -1,52 +0,0 @@
|
||||||
{ config, lib, ... }:
|
|
||||||
let
|
|
||||||
cfg = config.luj.mailserver;
|
|
||||||
in
|
|
||||||
with lib;
|
|
||||||
{
|
|
||||||
options.luj.mailserver = {
|
|
||||||
enable = mkEnableOption "Enable mailserver";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
mailserver = {
|
|
||||||
enable = true;
|
|
||||||
fqdn = "mail.julienmalka.me";
|
|
||||||
domains = [
|
|
||||||
"malka.sh"
|
|
||||||
"ens.school"
|
|
||||||
];
|
|
||||||
|
|
||||||
enableManageSieve = true;
|
|
||||||
|
|
||||||
# A list of all login accounts. To create the password hashes, use
|
|
||||||
# nix run nixpkgs.apacheHttpd -c htpasswd -nbB "" "super secret password" | cut -d: -f2
|
|
||||||
loginAccounts = {
|
|
||||||
"julien@malka.sh" = {
|
|
||||||
hashedPasswordFile = "/run/agenix/malkash-pw";
|
|
||||||
aliases = [ "@malka.sh" ];
|
|
||||||
sieveScript = builtins.readFile ./malka-sh.sieve;
|
|
||||||
};
|
|
||||||
"julien.malka@ens.school" = {
|
|
||||||
hashedPasswordFile = "/run/agenix/ensmailmalka-pw";
|
|
||||||
};
|
|
||||||
"camille.mondon@ens.school" = {
|
|
||||||
hashedPasswordFile = "/run/agenix/ensmailmondon-pw";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
extraVirtualAliases = {
|
|
||||||
"postmaster@ens.school" = "julien.malka@ens.school";
|
|
||||||
};
|
|
||||||
certificateScheme = "acme-nginx";
|
|
||||||
};
|
|
||||||
|
|
||||||
services.roundcube = {
|
|
||||||
enable = true;
|
|
||||||
hostName = "webmail.julienmalka.me";
|
|
||||||
};
|
|
||||||
|
|
||||||
age.secrets.malkash-pw.file = ../../secrets/julien-malka-sh-mail-password.age;
|
|
||||||
age.secrets.ensmailmalka-pw.file = ../../secrets/malka-ens-school-mail-password.age;
|
|
||||||
age.secrets.ensmailmondon-pw.file = ../../secrets/mondon-ens-school-mail-password.age;
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,56 +0,0 @@
|
||||||
require ["variables", "fileinto", "envelope", "subaddress", "mailbox"];
|
|
||||||
|
|
||||||
# rule:[FRnOG]
|
|
||||||
if allof (header :contains "subject" "[FRnOG]")
|
|
||||||
{
|
|
||||||
fileinto "INBOX.frnog";
|
|
||||||
stop;
|
|
||||||
}
|
|
||||||
# rule:[dn42]
|
|
||||||
if allof (header :contains "subject" "[dn42]")
|
|
||||||
{
|
|
||||||
fileinto "INBOX.dn42";
|
|
||||||
stop;
|
|
||||||
}
|
|
||||||
# rule:[Lobsters]
|
|
||||||
if allof (header :is "to" "lobsters-hQ3nfqM88Q@lobste.rs")
|
|
||||||
{
|
|
||||||
fileinto "INBOX.lobsters";
|
|
||||||
stop;
|
|
||||||
}
|
|
||||||
# rule:[Fosdem]
|
|
||||||
if allof (header :contains "subject" "[devroom-managers]")
|
|
||||||
{
|
|
||||||
fileinto "INBOX.fosdem";
|
|
||||||
stop;
|
|
||||||
}
|
|
||||||
# rule:[Promox]
|
|
||||||
if allof (header :contains "subject" "[pve-devel]")
|
|
||||||
{
|
|
||||||
fileinto "INBOX.proxmox";
|
|
||||||
stop;
|
|
||||||
}
|
|
||||||
# rule:[Github]
|
|
||||||
if allof (header :contains "from" "notifications@github.com")
|
|
||||||
{
|
|
||||||
fileinto "INBOX.github";
|
|
||||||
stop;
|
|
||||||
}
|
|
||||||
# rule:[Netdata]
|
|
||||||
if allof (header :contains "from" "netdata")
|
|
||||||
{
|
|
||||||
fileinto "INBOX.netdata";
|
|
||||||
stop;
|
|
||||||
}
|
|
||||||
#rule:[Lol]
|
|
||||||
if header :matches "X-Original-To" "*@malka.sh" {
|
|
||||||
set :lower "name" "${1}";
|
|
||||||
if string :is "${name}" "" {
|
|
||||||
fileinto "INBOX";
|
|
||||||
}
|
|
||||||
elsif string :is "${name}" "julien" {
|
|
||||||
fileinto "INBOX";
|
|
||||||
} else {
|
|
||||||
fileinto :create "INBOX.${name}";
|
|
||||||
}
|
|
||||||
}
|
|
Loading…
Add table
Reference in a new issue