flake: clean up modules

This commit is contained in:
Infinidoge 2024-10-22 11:34:51 -04:00
parent 28f18c9a99
commit 8cd8b3a3f9
Signed by: Infinidoge
SSH key fingerprint: SHA256:oAMyvotlNFraMmZmr+p6AxnNfW/GioTs1pOn3V4tQ7A
64 changed files with 258 additions and 273 deletions

View file

@ -1,11 +1,11 @@
{ config, lib, pkgs, ... }:
{ config, common, lib, pkgs, ... }:
let
domain = config.common.subdomain "bitwarden";
domain = common.subdomain "bitwarden";
in
{
persist.directories = [ config.services.vaultwarden.dataDir ];
services.nginx.virtualHosts.${domain} = config.common.nginx.ssl // {
services.nginx.virtualHosts.${domain} = common.nginx.ssl // {
locations."/" = {
proxyPass = "http://127.0.0.1:${toString config.services.vaultwarden.config.ROCKET_PORT}";
};
@ -15,7 +15,7 @@ in
enable = true;
environmentFile = config.secrets."vaultwarden";
dataDir = "/srv/vaultwarden";
config = with config.common.email; {
config = with common.email; {
DOMAIN = "https://${domain}";
SIGNUPS_ALLOWED = false;