blob: 449d96c4794c1ff78f0e78ddf56a89974976d246 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
{
config,
lib,
...
}:
with lib; let
cfg = config.nixfiles.modules.aria2;
in {
options.nixfiles.modules.aria2.enable = mkEnableOption "aria2";
config = mkIf cfg.enable {
hm.programs.aria2 = {
enable = true;
settings = {
bt-max-peers = 128;
bt-save-metadata = true;
continue = true;
enable-dht = true;
enable-peer-exchange = true;
enable-rpc = false;
follow-torrent = true;
log-level = "info";
max-connection-per-server = 16;
max-overall-upload-limit = "1K";
max-tries = 5;
max-upload-limit = "1K";
seed-ratio = 0.1;
seed-time = 0.1;
stream-piece-selector = "default";
timeout = 60;
};
};
};
}
|