mirror of
https://github.com/CHN-beta/nixos.git
synced 2026-01-12 04:39:23 +08:00
pc: enable beesd
This commit is contained in:
@@ -128,7 +128,7 @@ inputs:
|
||||
nix-serve = { enable = true; hostname = "nix-store.chn.moe"; };
|
||||
smartd.enable = true;
|
||||
misskey.instances.misskey.hostname = "xn--qbtm095lrg0bfka60z.chn.moe";
|
||||
beesd = { enable = false; instances.root = { device = "/"; hashTableSizeMB = 2048; }; };
|
||||
beesd = { enable = true; instances.root = { device = "/"; hashTableSizeMB = 2048; threads = 4; }; };
|
||||
wireguard =
|
||||
{
|
||||
enable = true;
|
||||
|
||||
@@ -8,8 +8,14 @@ inputs:
|
||||
type = types.attrsOf (types.oneOf
|
||||
[
|
||||
types.nonEmptyStr
|
||||
(types.submodule { options =
|
||||
{ device = mkOption { type = types.nonEmptyStr; }; hashTableSizeMB = mkOption { type = types.int; }; };})
|
||||
(types.submodule
|
||||
{
|
||||
options =
|
||||
{
|
||||
device = mkOption { type = types.nonEmptyStr; };
|
||||
hashTableSizeMB = mkOption { type = types.ints.unsigned; default = 1024; };
|
||||
threads = mkOption { type = types.ints.unsigned; default = 1; };
|
||||
};})
|
||||
]);
|
||||
default = {};
|
||||
};
|
||||
@@ -30,7 +36,7 @@ inputs:
|
||||
{
|
||||
spec = instance.value.device or instance.value;
|
||||
hashTableSizeMB = instance.value.hashTableSizeMB or 1024;
|
||||
extraOptions = [ "--thread-count" "1" "--scan-mode" "3" ];
|
||||
extraOptions = [ "--thread-count" "${toString instance.value.threads or 1}" "--scan-mode" "3" ];
|
||||
};
|
||||
})
|
||||
(attrsToList beesd.instances));
|
||||
|
||||
Reference in New Issue
Block a user