m: expose torrent-secrets

This commit is contained in:
makefu 2017-01-09 16:01:46 +01:00
parent 980ef46abe
commit 254ddab891
3 changed files with 17 additions and 2 deletions

View file

@ -8,13 +8,13 @@ let
peer-port = 51412; peer-port = 51412;
web-port = 8112; web-port = 8112;
daemon-port = 58846; daemon-port = 58846;
dl-dir = "/var/download"; dl-dir = config.makefu.dl-dir;
in { in {
# prepare secrets # prepare secrets
krebs.build.source.torrent-secrets.file = krebs.build.source.torrent-secrets.file =
if getEnv "dummy_secrets" == "true" if getEnv "dummy_secrets" == "true"
then toString <stockholm/makefu/6tests/data/secrets> then toString <stockholm/makefu/6tests/data/secrets>
else "/home/makefu/secrets/torrent"; else config.makefu.torrent-secrets ;
users.users = { users.users = {
download = { download = {

View file

@ -8,9 +8,11 @@ _:
./forward-journal.nix ./forward-journal.nix
./opentracker.nix ./opentracker.nix
./ps3netsrv.nix ./ps3netsrv.nix
./logging-config.nix
./server-config.nix ./server-config.nix
./snapraid.nix ./snapraid.nix
./taskserver.nix ./taskserver.nix
./torrent.nix
./udpt.nix ./udpt.nix
./umts.nix ./umts.nix
]; ];

13
3modules/torrent.nix Normal file
View file

@ -0,0 +1,13 @@
{config, lib, pkgs, ... }:
{
options.makefu.dl-dir = lib.mkOption {
type = lib.types.str;
description = "Default download directory";
default = "/media/cryptX/torrent";
};
options.makefu.torrent-secrets = lib.mkOption {
type = lib.types.str;
default = "/home/makefu/secrets/torrent";
};
}