fix: pass lib to backup module and fixup backup configuration
Signed-off-by: Chinmay D. Pai <chinmaydpai@gmail.com>
This commit is contained in:
parent
104d4b6c8d
commit
1a54eab3fb
@ -3,9 +3,7 @@
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib; let
|
||||
inherit (utils.systemdUtils.unitOptions) unitOption;
|
||||
in {
|
||||
with lib; {
|
||||
options.snowflake.services.backups = {
|
||||
enable = mkEnableOption "Enable restic backup service";
|
||||
|
||||
@ -27,7 +25,7 @@ in {
|
||||
default = {};
|
||||
type = types.attrsOf (
|
||||
types.submodule (
|
||||
{_}: {
|
||||
{lib, ...}: {
|
||||
options = {
|
||||
dynamicFilesFrom = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
@ -63,7 +61,6 @@ in {
|
||||
};
|
||||
|
||||
timerConfig = mkOption {
|
||||
type = types.attrsOf unitOption;
|
||||
default = {
|
||||
OnCalendar = "daily";
|
||||
};
|
||||
|
@ -64,7 +64,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
snowflake.services.backups.paperless.config = {
|
||||
snowflake.services.backups.config.paperless = {
|
||||
dynamicFilesFrom = let
|
||||
path = config.services.paperless.dataDir;
|
||||
in ''
|
||||
|
@ -77,7 +77,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
snowflake.services.backups.vaultwarden.paths = [
|
||||
snowflake.services.backups.config.vaultwarden.paths = [
|
||||
"/var/lib/bitwarden_rs"
|
||||
];
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user