Cleanup nodes that are not reachable anymore

This commit is contained in:
Eike Kettner
2021-02-18 00:34:37 +01:00
parent b16166f1e9
commit d7bc963450
9 changed files with 139 additions and 7 deletions

View File

@ -58,6 +58,10 @@ let
enabled = true;
older-than = "30 days";
};
check-nodes = {
enabled = true;
min-not-found = 2;
};
};
extraction = {
pdf = {
@ -540,6 +544,24 @@ in {
default = defaults.house-keeping.cleanup-remember-me;
description = "Settings for cleaning up remember me tokens.";
};
check-nodes = mkOption {
type = types.submodule({
options = {
enabled = mkOption {
type = types.bool;
default = defaults.house-keeping.check-nodes.enabled;
description = "Whether this task is enabled.";
};
min-not-found = mkOption {
type = types.int;
default = defaults.house-keeping.check-nodes.min-not-found;
description = "How often the node must be unreachable, before it is removed.";
};
};
});
default = defaults.house-keeping.cleanup-nodes;
description = "Removes node entries that are not reachable anymore.";
};
};
});
default = defaults.house-keeping;