Add missing configs to nix modules

This commit is contained in:
Eike Kettner 2020-12-14 14:51:56 +01:00
parent 398f969207
commit 5681581bf8
2 changed files with 44 additions and 0 deletions

View File

@ -54,6 +54,10 @@ let
older-than = "30 days";
delete-batch = 100;
};
cleanup-remember-me = {
enabled = true;
older-than = "30 days";
};
};
extraction = {
pdf = {
@ -517,6 +521,24 @@ in {
of old files can be removed eventually.
'';
};
cleanup-remember-me = mkOption {
type = types.submodule({
options = {
enabled = mkOption {
type = types.bool;
default = defaults.house-keeping.cleanup-remember-me.enabled;
description = "Whether this task is enabled.";
};
older-than = mkOption {
type = types.str;
default = defaults.house-keeping.cleanup-remember-me.older-than;
description = "The miminum age of remember me tokens to delete.";
};
};
});
default = defaults.house-keeping.cleanup-remember-me;
description = "Settings for cleaning up remember me tokens.";
};
};
});
default = defaults.house-keeping;

View File

@ -54,6 +54,10 @@ let
auth = {
server-secret = "hex:caffee";
session-valid = "5 minutes";
remember-me = {
enabled = true;
valid = "30 days";
};
};
backend = {
mail-debug = false;
@ -196,6 +200,24 @@ in {
will get a new one periodically.
'';
};
remember-me = mkOption {
type = types.submodule({
options = {
enabled = mkOption {
type = types.bool;
default = defaults.auth.remember-me.enabled;
description = "Whether to enable remember me.";
};
valid = mkOption {
type = types.str;
default = defaults.auth.remember-me.valid;
description = "The time a remember-me token is valid.";
};
};
});
default = defaults.auth.remember-me;
description = "Settings for Remember-Me";
};
};
});
default = defaults.auth;