rice/hosts/ami/bitwarden.nix
buffet 2def5b10eb
All checks were successful
/ check (push) Successful in 2m44s
refactor: move repeated nginx snippets into one file
2024-06-05 09:40:42 +00:00

28 lines
597 B
Nix

{config, ...}: let
port = 12224;
in {
age.secrets.bitwarden.file = ../../secrets/bitwarden.age;
services = {
vaultwarden = {
enable = true;
environmentFile = config.age.secrets.bitwarden.path;
config = {
domain = "https://bitwarden.buffet.sh/";
signupsAllowed = false;
rocketPort = port;
};
};
nginx = {
virtualHosts."bitwarden.buffet.sh" = {
useACMEHost = "buffet.sh";
forceSSL = true;
locations."/" = {
proxyPass = "http://localhost:${toString port}";
};
};
};
};
}