bitwarden: move to postgresql
This commit is contained in:
@@ -9,21 +9,16 @@
|
|||||||
imports = [
|
imports = [
|
||||||
(lib.serviceMountWithZpool "vaultwarden" service_configs.zpool_ssds [
|
(lib.serviceMountWithZpool "vaultwarden" service_configs.zpool_ssds [
|
||||||
service_configs.vaultwarden.path
|
service_configs.vaultwarden.path
|
||||||
config.services.vaultwarden.backupDir
|
|
||||||
])
|
|
||||||
(lib.serviceMountWithZpool "backup-vaultwarden" service_configs.zpool_ssds [
|
|
||||||
service_configs.vaultwarden.path
|
|
||||||
config.services.vaultwarden.backupDir
|
|
||||||
])
|
])
|
||||||
(lib.serviceFilePerms "vaultwarden" [
|
(lib.serviceFilePerms "vaultwarden" [
|
||||||
"Z ${service_configs.vaultwarden.path} 0700 vaultwarden vaultwarden"
|
"Z ${service_configs.vaultwarden.path} 0700 vaultwarden vaultwarden"
|
||||||
"Z ${config.services.vaultwarden.backupDir} 0700 vaultwarden vaultwarden"
|
|
||||||
])
|
])
|
||||||
];
|
];
|
||||||
|
|
||||||
services.vaultwarden = {
|
services.vaultwarden = {
|
||||||
enable = true;
|
enable = true;
|
||||||
backupDir = "/${service_configs.zpool_ssds}/bak/vaultwarden";
|
dbBackend = "postgresql";
|
||||||
|
configurePostgres = true;
|
||||||
config = {
|
config = {
|
||||||
# Refer to https://github.com/dani-garcia/vaultwarden/blob/main/.env.template
|
# Refer to https://github.com/dani-garcia/vaultwarden/blob/main/.env.template
|
||||||
DOMAIN = "https://bitwarden.${service_configs.https.domain}";
|
DOMAIN = "https://bitwarden.${service_configs.https.domain}";
|
||||||
|
|||||||
Reference in New Issue
Block a user