feat: massive refactoring...

This commit is contained in:
Xavier Morel
2025-11-09 00:45:00 +01:00
parent f9446df46d
commit 3245b6b89f
77 changed files with 3233 additions and 582 deletions

View File

@@ -0,0 +1,29 @@
{
pkgs,
config,
tools,
...
}:
let
container = "vault";
hostname = tools.build_hostname container;
db_host = tools.build_ip "db";
db_password = config.my-lxc.vault.db.password;
in
{
services.vaultwarden = {
enable = true;
config = {
DISABLE_ADMIN_TOKEN = true;
ROCKET_ADDRESS = "0.0.0.0";
ROCKET_PORT = config.my-lxc.vault.system.port;
DOMAIN = "https://${hostname}";
SIGNUPS_ALLOWED = false;
DATABASE_URL = "postgresql://${container}:${db_password}@${db_host}:5432/${container}";
WEB_VAULT_ENABLED = true;
INVITATIONS_ENABLED = true;
ORG_CREATION_USERS = config.globals.master.email;
};
dbBackend = "postgresql";
};
}