chore: fuck roundcube

This commit is contained in:
Nick 2025-10-22 02:33:13 -05:00
parent 3773d01b25
commit 1b98c4eff8
3 changed files with 16 additions and 114 deletions

View file

@ -1,43 +0,0 @@
{ moduleFunctions }:
let
inherit (moduleFunctions.instancesFunctions)
domain0
servicePath
sslPath
sopsPath
;
label = "Roundcube";
name = "roundcube";
subdomain = "mail";
domain = "${subdomain}.${domain0}";
in
{
label = label;
name = name;
short = "Round";
email = {
address0 = "noreply@${domain0}";
};
sops = {
path0 = "${sopsPath}/${name}";
};
domains = {
url0 = domain;
};
subdomain = subdomain;
tags = [
name
"email"
];
paths = {
path0 = "${servicePath}/${label}";
};
ports = {
port0 = 9999;
};
ssl = {
cert = "${sslPath}/${domain}/fullchain.pem";
key = "${sslPath}/${domain}/key.pem";
};
}

View file

@ -36,19 +36,19 @@ in
value = dnsConfig dns0Path dns0;
})
[
"audiobookshelf"
"glance"
"jellyfin"
"minecraft"
"nextcloud"
"ollama"
"searx"
"syncthing"
"vaultwarden"
"opencloud"
"prompter"
"comfyui"
"firefly-iii"
instances.audiobookshelf.name
instances.glance.name
instances.jellyfin.name
instances.minecraft.name
instances.nextcloud.name
instances.ollama.name
instances.searx.name
instances.syncthing.name
instances.vaultwarden.name
instances.opencloud.name
instances.prompter.name
instances.comfyui.name
instances.firefly-iii.name
]
)
++ (map
@ -57,9 +57,9 @@ in
value = dnsConfig dns0Path dns0;
})
[
"forgejo"
"mastodon"
"peertube"
instances.forgejo.name
instances.mastodon.name
instances.peertube.name
]
)
++ (map

View file

@ -1,55 +0,0 @@
{
pkgs,
flake,
config,
...
}:
let
inherit (flake.config.services.instances) roundcube web;
service = roundcube;
host = service.domains.address0;
in
{
services = {
roundcube = {
enable = true;
configureNginx = false;
dicts = builtins.attrValues {
inherit (pkgs.aspellDicts)
en
;
};
plugins = [
];
# hostName = host;
database = {
host = web.localhost.address1;
dbname = service.name;
username = "";
passwordFile = config.sops.secrets."${service.name}-pass".path;
};
};
};
sops =
let
sopsPath = secret: {
path = "${service.sops.path0}/${service.name}-${secret}";
owner = "root";
mode = "600";
};
in
{
secrets = builtins.listToAttrs (
map
(secret: {
name = "${service.name}-${secret}";
value = sopsPath secret;
})
[
"pass"
]
);
};
}