Improved docs
This commit is contained in:
@@ -12,6 +12,7 @@ in {
|
|||||||
enable = mkOption {
|
enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:**
|
**Required options:**
|
||||||
|
|
||||||
@@ -25,6 +26,7 @@ in {
|
|||||||
keysFile = mkOption {
|
keysFile = mkOption {
|
||||||
type = with types; nullOr path;
|
type = with types; nullOr path;
|
||||||
default = null;
|
default = null;
|
||||||
|
example = "/data/.secret/njalla/keys-file.json";
|
||||||
description = ''
|
description = ''
|
||||||
A path to a JSON-file containing key value pairs of domains and keys.
|
A path to a JSON-file containing key value pairs of domains and keys.
|
||||||
|
|
||||||
|
|||||||
@@ -15,12 +15,14 @@ in with lib; {
|
|||||||
type = types.path;
|
type = types.path;
|
||||||
default = "${nixarr.stateDir}/jellyfin";
|
default = "${nixarr.stateDir}/jellyfin";
|
||||||
defaultText = literalExpression ''"''${nixarr.stateDir}/jellyfin"'';
|
defaultText = literalExpression ''"''${nixarr.stateDir}/jellyfin"'';
|
||||||
|
example = "/home/user/.local/share/nixarr/jellyfin";
|
||||||
description = "The state directory for Jellyfin.";
|
description = "The state directory for Jellyfin.";
|
||||||
};
|
};
|
||||||
|
|
||||||
vpn.enable = mkOption {
|
vpn.enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
||||||
**Conflicting options:** [`nixarr.jellyfin.expose.https.enable`](#nixarr.jellyfin.expose.https.enable)
|
**Conflicting options:** [`nixarr.jellyfin.expose.https.enable`](#nixarr.jellyfin.expose.https.enable)
|
||||||
@@ -34,6 +36,7 @@ in with lib; {
|
|||||||
enable = mkOption {
|
enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:**
|
**Required options:**
|
||||||
|
|
||||||
@@ -52,6 +55,7 @@ in with lib; {
|
|||||||
port = mkOption {
|
port = mkOption {
|
||||||
type = with types; nullOr port;
|
type = with types; nullOr port;
|
||||||
default = null;
|
default = null;
|
||||||
|
example = 12345;
|
||||||
description = ''
|
description = ''
|
||||||
The port to access jellyfin on. Get this port from your VPN
|
The port to access jellyfin on. Get this port from your VPN
|
||||||
provider.
|
provider.
|
||||||
@@ -72,6 +76,7 @@ in with lib; {
|
|||||||
enable = mkOption {
|
enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:**
|
**Required options:**
|
||||||
|
|
||||||
@@ -93,12 +98,14 @@ in with lib; {
|
|||||||
domainName = mkOption {
|
domainName = mkOption {
|
||||||
type = types.nullOr types.str;
|
type = types.nullOr types.str;
|
||||||
default = null;
|
default = null;
|
||||||
|
example = "jellyfin.example.com";
|
||||||
description = "The domain name to host Jellyfin on.";
|
description = "The domain name to host Jellyfin on.";
|
||||||
};
|
};
|
||||||
|
|
||||||
acmeMail = mkOption {
|
acmeMail = mkOption {
|
||||||
type = types.nullOr types.str;
|
type = types.nullOr types.str;
|
||||||
default = null;
|
default = null;
|
||||||
|
example = "mail@example.com";
|
||||||
description = "The ACME mail required for the letsencrypt bot.";
|
description = "The ACME mail required for the letsencrypt bot.";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -14,12 +14,14 @@ in {
|
|||||||
type = types.path;
|
type = types.path;
|
||||||
default = "${nixarr.stateDir}/lidarr";
|
default = "${nixarr.stateDir}/lidarr";
|
||||||
defaultText = literalExpression ''"''${nixarr.stateDir}/lidarr"'';
|
defaultText = literalExpression ''"''${nixarr.stateDir}/lidarr"'';
|
||||||
|
example = "/home/user/.local/share/nixarr/lidarr";
|
||||||
description = "The state directory for Lidarr";
|
description = "The state directory for Lidarr";
|
||||||
};
|
};
|
||||||
|
|
||||||
vpn.enable = mkOption {
|
vpn.enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
||||||
|
|
||||||
|
|||||||
+6
-1
@@ -24,6 +24,7 @@ in {
|
|||||||
enable = mkOption {
|
enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
Whether or not to enable the nixarr module. Has the following features:
|
Whether or not to enable the nixarr module. Has the following features:
|
||||||
|
|
||||||
@@ -58,6 +59,7 @@ in {
|
|||||||
mediaDir = mkOption {
|
mediaDir = mkOption {
|
||||||
type = types.path;
|
type = types.path;
|
||||||
default = "/data/media";
|
default = "/data/media";
|
||||||
|
example = "/home/user/nixarr";
|
||||||
description = ''
|
description = ''
|
||||||
The location of the media directory for the services.
|
The location of the media directory for the services.
|
||||||
'';
|
'';
|
||||||
@@ -66,6 +68,7 @@ in {
|
|||||||
stateDir = mkOption {
|
stateDir = mkOption {
|
||||||
type = types.path;
|
type = types.path;
|
||||||
default = "/data/.state/nixarr";
|
default = "/data/.state/nixarr";
|
||||||
|
example = "/home/user/.local/share/nixarr";
|
||||||
description = ''
|
description = ''
|
||||||
The location of the state directory for the services.
|
The location of the state directory for the services.
|
||||||
'';
|
'';
|
||||||
@@ -75,6 +78,7 @@ in {
|
|||||||
enable = mkOption {
|
enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:** [`nixarr.vpn.wgConf`](#nixarr.vpn.wgconf)
|
**Required options:** [`nixarr.vpn.wgConf`](#nixarr.vpn.wgconf)
|
||||||
|
|
||||||
@@ -86,6 +90,7 @@ in {
|
|||||||
wgConf = mkOption {
|
wgConf = mkOption {
|
||||||
type = types.nullOr types.path;
|
type = types.nullOr types.path;
|
||||||
default = null;
|
default = null;
|
||||||
|
example = "/data/.secret/vpn/wg.conf";
|
||||||
description = "The path to the wireguard configuration file.";
|
description = "The path to the wireguard configuration file.";
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -98,11 +103,11 @@ in {
|
|||||||
port = mkOption {
|
port = mkOption {
|
||||||
type = with types; nullOr port;
|
type = with types; nullOr port;
|
||||||
default = null;
|
default = null;
|
||||||
|
example = 58403;
|
||||||
description = ''
|
description = ''
|
||||||
The port that netcat listens to on the vpn test service. If set to
|
The port that netcat listens to on the vpn test service. If set to
|
||||||
`null`, then netcat will not be started.
|
`null`, then netcat will not be started.
|
||||||
'';
|
'';
|
||||||
example = 58403;
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -10,6 +10,7 @@ in {
|
|||||||
options.nixarr.openssh.expose.vpn.enable = mkOption {
|
options.nixarr.openssh.expose.vpn.enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
||||||
|
|
||||||
|
|||||||
@@ -20,12 +20,14 @@ in {
|
|||||||
type = types.path;
|
type = types.path;
|
||||||
default = "${nixarr.stateDir}/prowlarr";
|
default = "${nixarr.stateDir}/prowlarr";
|
||||||
defaultText = literalExpression ''"''${nixarr.stateDir}/prowlarr"'';
|
defaultText = literalExpression ''"''${nixarr.stateDir}/prowlarr"'';
|
||||||
|
example = "/home/user/.local/share/nixarr/prowlarr";
|
||||||
description = "The state directory for Prowlarr.";
|
description = "The state directory for Prowlarr.";
|
||||||
};
|
};
|
||||||
|
|
||||||
vpn.enable = mkOption {
|
vpn.enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
||||||
|
|
||||||
|
|||||||
@@ -16,12 +16,14 @@ in {
|
|||||||
type = types.path;
|
type = types.path;
|
||||||
default = "${nixarr.stateDir}/radarr";
|
default = "${nixarr.stateDir}/radarr";
|
||||||
defaultText = literalExpression ''"''${nixarr.stateDir}/radarr"'';
|
defaultText = literalExpression ''"''${nixarr.stateDir}/radarr"'';
|
||||||
|
example = "/home/user/.local/share/nixarr/radarr";
|
||||||
description = "The state directory for radarr.";
|
description = "The state directory for radarr.";
|
||||||
};
|
};
|
||||||
|
|
||||||
vpn.enable = mkOption {
|
vpn.enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
||||||
|
|
||||||
|
|||||||
@@ -14,12 +14,14 @@ in {
|
|||||||
type = types.path;
|
type = types.path;
|
||||||
default = "${nixarr.stateDir}/readarr";
|
default = "${nixarr.stateDir}/readarr";
|
||||||
defaultText = literalExpression ''"''${nixarr.stateDir}/readarr"'';
|
defaultText = literalExpression ''"''${nixarr.stateDir}/readarr"'';
|
||||||
|
example = "/home/user/.local/share/nixarr/readarr";
|
||||||
description = "The state directory for Readarr";
|
description = "The state directory for Readarr";
|
||||||
};
|
};
|
||||||
|
|
||||||
vpn.enable = mkOption {
|
vpn.enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
||||||
|
|
||||||
|
|||||||
@@ -20,12 +20,14 @@ in {
|
|||||||
type = types.path;
|
type = types.path;
|
||||||
default = "${nixarr.stateDir}/sonarr";
|
default = "${nixarr.stateDir}/sonarr";
|
||||||
defaultText = literalExpression ''"''${nixarr.stateDir}/sonarr"'';
|
defaultText = literalExpression ''"''${nixarr.stateDir}/sonarr"'';
|
||||||
|
example = "/home/user/.local/share/nixarr/sonarr";
|
||||||
description = "The state directory for Sonarr.";
|
description = "The state directory for Sonarr.";
|
||||||
};
|
};
|
||||||
|
|
||||||
vpn.enable = mkOption {
|
vpn.enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
||||||
|
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ with lib; let
|
|||||||
cfg = config.nixarr.transmission;
|
cfg = config.nixarr.transmission;
|
||||||
nixarr = config.nixarr;
|
nixarr = config.nixarr;
|
||||||
cfg-cross-seed = config.nixarr.transmission.privateTrackers.cross-seed;
|
cfg-cross-seed = config.nixarr.transmission.privateTrackers.cross-seed;
|
||||||
|
downloadDir = "${nixarr.mediaDir}/torrents";
|
||||||
transmissionCrossSeedScript = with builtins; pkgs.writeShellApplication {
|
transmissionCrossSeedScript = with builtins; pkgs.writeShellApplication {
|
||||||
name = "transmission-cross-seed-script";
|
name = "transmission-cross-seed-script";
|
||||||
|
|
||||||
@@ -67,23 +68,16 @@ in {
|
|||||||
type = types.path;
|
type = types.path;
|
||||||
default = "${nixarr.stateDir}/transmission";
|
default = "${nixarr.stateDir}/transmission";
|
||||||
defaultText = literalExpression ''"''${nixarr.stateDir}/transmission"'';
|
defaultText = literalExpression ''"''${nixarr.stateDir}/transmission"'';
|
||||||
|
example = "/home/user/.local/share/nixarr/transmission";
|
||||||
description = ''
|
description = ''
|
||||||
The state directory for Transmission.
|
The state directory for Transmission.
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
downloadDir = mkOption {
|
|
||||||
type = types.path;
|
|
||||||
default = "${nixarr.mediaDir}/torrents";
|
|
||||||
defaultText = literalExpression ''"''${nixarr.mediaDir}/torrents"'';
|
|
||||||
description = ''
|
|
||||||
The directory for Transmission to download to.
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
vpn.enable = mkOption {
|
vpn.enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
**Required options:** [`nixarr.vpn.enable`](#nixarr.vpn.enable)
|
||||||
|
|
||||||
@@ -97,6 +91,7 @@ in {
|
|||||||
disableDhtPex = mkOption {
|
disableDhtPex = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
Disable pex and dht, which is required for some private trackers.
|
Disable pex and dht, which is required for some private trackers.
|
||||||
|
|
||||||
@@ -112,6 +107,7 @@ in {
|
|||||||
enable = mkOption {
|
enable = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
example = true;
|
||||||
description = ''
|
description = ''
|
||||||
**Required options:** [`nixarr.prowlarr.enable`](#nixarr.prowlarr.enable)
|
**Required options:** [`nixarr.prowlarr.enable`](#nixarr.prowlarr.enable)
|
||||||
|
|
||||||
@@ -123,6 +119,7 @@ in {
|
|||||||
type = types.path;
|
type = types.path;
|
||||||
default = "${nixarr.stateDir}/cross-seed";
|
default = "${nixarr.stateDir}/cross-seed";
|
||||||
defaultText = literalExpression ''"''${nixarr.stateDir}/cross-seed"'';
|
defaultText = literalExpression ''"''${nixarr.stateDir}/cross-seed"'';
|
||||||
|
example = "/home/user/.local/share/nixarr/cross-seed";
|
||||||
description = ''
|
description = ''
|
||||||
The state directory for Transmission.
|
The state directory for Transmission.
|
||||||
'';
|
'';
|
||||||
@@ -170,18 +167,21 @@ in {
|
|||||||
"trace"
|
"trace"
|
||||||
];
|
];
|
||||||
default = "warn";
|
default = "warn";
|
||||||
|
example = "debug";
|
||||||
description = "Sets the message level of transmission.";
|
description = "Sets the message level of transmission.";
|
||||||
};
|
};
|
||||||
|
|
||||||
peerPort = mkOption {
|
peerPort = mkOption {
|
||||||
type = types.port;
|
type = types.port;
|
||||||
default = 50000;
|
default = 50000;
|
||||||
|
example = 12345;
|
||||||
description = "Transmission peer traffic port.";
|
description = "Transmission peer traffic port.";
|
||||||
};
|
};
|
||||||
|
|
||||||
uiPort = mkOption {
|
uiPort = mkOption {
|
||||||
type = types.port;
|
type = types.port;
|
||||||
default = 9091;
|
default = 9091;
|
||||||
|
example = 12345;
|
||||||
description = "Transmission web-UI port.";
|
description = "Transmission web-UI port.";
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -277,11 +277,11 @@ in {
|
|||||||
openPeerPorts = true;
|
openPeerPorts = true;
|
||||||
settings =
|
settings =
|
||||||
{
|
{
|
||||||
download-dir = "${nixarr.mediaDir}/torrents";
|
download-dir = downloadDir;
|
||||||
incomplete-dir-enabled = true;
|
incomplete-dir-enabled = true;
|
||||||
incomplete-dir = "${nixarr.mediaDir}/torrents/.incomplete";
|
incomplete-dir = "${downloadDir}/.incomplete";
|
||||||
watch-dir-enabled = true;
|
watch-dir-enabled = true;
|
||||||
watch-dir = "${nixarr.mediaDir}/torrents/.watch";
|
watch-dir = "${downloadDir}/.watch";
|
||||||
|
|
||||||
rpc-bind-address = if cfg.vpn.enable then "192.168.15.1" else "127.0.0.1";
|
rpc-bind-address = if cfg.vpn.enable then "192.168.15.1" else "127.0.0.1";
|
||||||
rpc-port = cfg.uiPort;
|
rpc-port = cfg.uiPort;
|
||||||
|
|||||||
Reference in New Issue
Block a user