summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/modules.nix2
-rw-r--r--nixos/modules/config/networking.nix8
-rw-r--r--nixos/modules/config/system-path.nix22
-rw-r--r--nixos/modules/hardware/system-76.nix8
-rw-r--r--nixos/modules/misc/version.nix4
-rw-r--r--nixos/modules/programs/captive-browser.nix26
-rw-r--r--nixos/modules/programs/gnupg.nix1
-rw-r--r--nixos/modules/programs/zsh/zsh.nix4
-rw-r--r--nixos/modules/security/acme.nix2
-rw-r--r--nixos/modules/security/dhparams.nix6
-rw-r--r--nixos/modules/services/audio/mpdscribble.nix13
-rw-r--r--nixos/modules/services/backup/tarsnap.nix9
-rw-r--r--nixos/modules/services/cluster/hadoop/default.nix14
-rw-r--r--nixos/modules/services/cluster/kubernetes/addons/dashboard.nix14
-rw-r--r--nixos/modules/services/cluster/kubernetes/addons/dns.nix6
-rw-r--r--nixos/modules/services/cluster/kubernetes/apiserver.nix7
-rw-r--r--nixos/modules/services/cluster/kubernetes/controller-manager.nix6
-rw-r--r--nixos/modules/services/cluster/kubernetes/default.nix4
-rw-r--r--nixos/modules/services/cluster/kubernetes/kubelet.nix7
-rw-r--r--nixos/modules/services/cluster/kubernetes/proxy.nix4
-rw-r--r--nixos/modules/services/cluster/kubernetes/scheduler.nix4
-rw-r--r--nixos/modules/services/computing/slurm/slurm.nix9
-rw-r--r--nixos/modules/services/continuous-integration/buildbot/master.nix4
-rw-r--r--nixos/modules/services/continuous-integration/buildbot/worker.nix4
-rw-r--r--nixos/modules/services/continuous-integration/gocd-agent/default.nix12
-rw-r--r--nixos/modules/services/continuous-integration/gocd-server/default.nix17
-rw-r--r--nixos/modules/services/databases/hbase.nix21
-rw-r--r--nixos/modules/services/databases/neo4j.nix8
-rw-r--r--nixos/modules/services/games/quake3-server.nix1
-rw-r--r--nixos/modules/services/games/terraria.nix5
-rw-r--r--nixos/modules/services/hardware/tcsd.nix6
-rw-r--r--nixos/modules/services/logging/journalbeat.nix16
-rw-r--r--nixos/modules/services/mail/rspamd.nix5
-rw-r--r--nixos/modules/services/misc/airsonic.nix5
-rw-r--r--nixos/modules/services/misc/etcd.nix9
-rw-r--r--nixos/modules/services/misc/exhibitor.nix5
-rw-r--r--nixos/modules/services/misc/gitea.nix13
-rw-r--r--nixos/modules/services/misc/gitlab.nix5
-rw-r--r--nixos/modules/services/misc/gitweb.nix1
-rw-r--r--nixos/modules/services/misc/gogs.nix5
-rw-r--r--nixos/modules/services/misc/headphones.nix4
-rw-r--r--nixos/modules/services/misc/matrix-appservice-discord.nix4
-rw-r--r--nixos/modules/services/misc/matrix-synapse.nix32
-rw-r--r--nixos/modules/services/misc/mediatomb.nix10
-rw-r--r--nixos/modules/services/misc/moonraker.nix4
-rw-r--r--nixos/modules/services/misc/mwlib.nix12
-rw-r--r--nixos/modules/services/misc/rippled.nix6
-rw-r--r--nixos/modules/services/misc/sickbeard.nix4
-rw-r--r--nixos/modules/services/misc/sourcehut/builds.nix6
-rw-r--r--nixos/modules/services/misc/sourcehut/dispatch.nix4
-rw-r--r--nixos/modules/services/misc/sourcehut/git.nix4
-rw-r--r--nixos/modules/services/misc/sourcehut/hg.nix4
-rw-r--r--nixos/modules/services/misc/sourcehut/hub.nix4
-rw-r--r--nixos/modules/services/misc/sourcehut/lists.nix4
-rw-r--r--nixos/modules/services/misc/sourcehut/man.nix4
-rw-r--r--nixos/modules/services/misc/sourcehut/meta.nix4
-rw-r--r--nixos/modules/services/misc/sourcehut/paste.nix4
-rw-r--r--nixos/modules/services/misc/sourcehut/todo.nix4
-rw-r--r--nixos/modules/services/misc/subsonic.nix9
-rw-r--r--nixos/modules/services/misc/zoneminder.nix2
-rw-r--r--nixos/modules/services/monitoring/grafana.nix1
-rw-r--r--nixos/modules/services/monitoring/graphite.nix12
-rw-r--r--nixos/modules/services/monitoring/parsedmarc.nix6
-rw-r--r--nixos/modules/services/monitoring/smartd.nix4
-rw-r--r--nixos/modules/services/monitoring/thanos.nix3
-rw-r--r--nixos/modules/services/monitoring/uptime.nix10
-rw-r--r--nixos/modules/services/monitoring/zabbix-proxy.nix8
-rw-r--r--nixos/modules/services/monitoring/zabbix-server.nix8
-rw-r--r--nixos/modules/services/networking/amuled.nix6
-rw-r--r--nixos/modules/services/networking/ergo.nix6
-rw-r--r--nixos/modules/services/networking/firewall.nix1
-rw-r--r--nixos/modules/services/networking/jibri/default.nix2
-rw-r--r--nixos/modules/services/networking/ntopng.nix7
-rw-r--r--nixos/modules/services/networking/quassel.nix6
-rw-r--r--nixos/modules/services/networking/quorum.nix4
-rw-r--r--nixos/modules/services/networking/syncthing.nix24
-rw-r--r--nixos/modules/services/networking/wasabibackend.nix6
-rw-r--r--nixos/modules/services/networking/wireguard.nix4
-rw-r--r--nixos/modules/services/networking/wpa_supplicant.nix4
-rw-r--r--nixos/modules/services/search/kibana.nix6
-rw-r--r--nixos/modules/services/security/privacyidea.nix6
-rw-r--r--nixos/modules/services/security/tor.nix8
-rw-r--r--nixos/modules/services/security/vault.nix8
-rw-r--r--nixos/modules/services/torrent/peerflix.nix4
-rw-r--r--nixos/modules/services/torrent/rtorrent.nix4
-rw-r--r--nixos/modules/services/torrent/transmission.nix4
-rw-r--r--nixos/modules/services/video/epgstation/default.nix8
-rw-r--r--nixos/modules/services/video/unifi-video.nix4
-rw-r--r--nixos/modules/services/web-apps/discourse.nix3
-rw-r--r--nixos/modules/services/web-apps/galene.nix6
-rw-r--r--nixos/modules/services/web-apps/hedgedoc.nix2
-rw-r--r--nixos/modules/services/web-apps/invidious.nix1
-rw-r--r--nixos/modules/services/web-apps/keycloak.nix5
-rw-r--r--nixos/modules/services/web-apps/matomo.nix14
-rw-r--r--nixos/modules/services/web-apps/nextcloud.nix1
-rw-r--r--nixos/modules/services/web-apps/peertube.nix19
-rw-r--r--nixos/modules/services/web-apps/pgpkeyserver-lite.nix5
-rw-r--r--nixos/modules/services/web-apps/zabbix.nix8
-rw-r--r--nixos/modules/services/web-servers/lighttpd/collectd.nix6
-rw-r--r--nixos/modules/services/x11/display-managers/default.nix14
-rw-r--r--nixos/modules/services/x11/hardware/synaptics.nix7
-rw-r--r--nixos/modules/services/x11/picom.nix14
-rw-r--r--nixos/modules/system/activation/activation-script.nix1
-rw-r--r--nixos/modules/system/boot/plymouth.nix8
-rw-r--r--nixos/modules/tasks/filesystems/zfs.nix5
-rw-r--r--nixos/modules/tasks/network-interfaces.nix4
-rw-r--r--nixos/modules/virtualisation/cri-o.nix4
107 files changed, 591 insertions, 161 deletions
diff --git a/lib/modules.nix b/lib/modules.nix
index e3bb27aa9462..573bf40e4b34 100644
--- a/lib/modules.nix
+++ b/lib/modules.nix
@@ -614,6 +614,8 @@ rec {
definitions = map (def: def.value) res.defsFinal;
files = map (def: def.file) res.defsFinal;
inherit (res) isDefined;
+ # This allows options to be correctly displayed using `${options.path.to.it}`
+ __toString = _: showOption loc;
};
# Merge definitions of a value of a given type.
diff --git a/nixos/modules/config/networking.nix b/nixos/modules/config/networking.nix
index 11307e331200..133a150df82c 100644
--- a/nixos/modules/config/networking.nix
+++ b/nixos/modules/config/networking.nix
@@ -1,12 +1,13 @@
# /etc files related to networking, such as /etc/services.
-{ config, lib, pkgs, ... }:
+{ config, lib, options, pkgs, ... }:
with lib;
let
cfg = config.networking;
+ opt = options.networking;
localhostMultiple = any (elem "localhost") (attrValues (removeAttrs cfg.hosts [ "127.0.0.1" "::1" ]));
@@ -78,6 +79,7 @@ in
httpProxy = lib.mkOption {
type = types.nullOr types.str;
default = cfg.proxy.default;
+ defaultText = literalExpression "config.${opt.proxy.default}";
description = ''
This option specifies the http_proxy environment variable.
'';
@@ -87,6 +89,7 @@ in
httpsProxy = lib.mkOption {
type = types.nullOr types.str;
default = cfg.proxy.default;
+ defaultText = literalExpression "config.${opt.proxy.default}";
description = ''
This option specifies the https_proxy environment variable.
'';
@@ -96,6 +99,7 @@ in
ftpProxy = lib.mkOption {
type = types.nullOr types.str;
default = cfg.proxy.default;
+ defaultText = literalExpression "config.${opt.proxy.default}";
description = ''
This option specifies the ftp_proxy environment variable.
'';
@@ -105,6 +109,7 @@ in
rsyncProxy = lib.mkOption {
type = types.nullOr types.str;
default = cfg.proxy.default;
+ defaultText = literalExpression "config.${opt.proxy.default}";
description = ''
This option specifies the rsync_proxy environment variable.
'';
@@ -114,6 +119,7 @@ in
allProxy = lib.mkOption {
type = types.nullOr types.str;
default = cfg.proxy.default;
+ defaultText = literalExpression "config.${opt.proxy.default}";
description = ''
This option specifies the all_proxy environment variable.
'';
diff --git a/nixos/modules/config/system-path.nix b/nixos/modules/config/system-path.nix
index 6ff4ec2921cf..875c4c9c4415 100644
--- a/nixos/modules/config/system-path.nix
+++ b/nixos/modules/config/system-path.nix
@@ -41,12 +41,17 @@ let
pkgs.zstd
];
- defaultPackages = map (pkg: setPrio ((pkg.meta.priority or 5) + 3) pkg)
- [ pkgs.nano
- pkgs.perl
- pkgs.rsync
- pkgs.strace
- ];
+ defaultPackageNames =
+ [ "nano"
+ "perl"
+ "rsync"
+ "strace"
+ ];
+ defaultPackages =
+ map
+ (n: let pkg = pkgs.${n}; in setPrio ((pkg.meta.priority or 5) + 3) pkg)
+ defaultPackageNames;
+ defaultPackagesText = "[ ${concatMapStringsSep " " (n: "pkgs.${n}") defaultPackageNames } ]";
in
@@ -73,6 +78,11 @@ in
defaultPackages = mkOption {
type = types.listOf types.package;
default = defaultPackages;
+ defaultText = literalDocBook ''
+ these packages, with their <literal>meta.priority</literal> numerically increased
+ (thus lowering their installation priority):
+ <programlisting>${defaultPackagesText}</programlisting>
+ '';
example = [];
description = ''
Set of default packages that aren't strictly necessary
diff --git a/nixos/modules/hardware/system-76.nix b/nixos/modules/hardware/system-76.nix
index d4896541dbae..ca40ee0ebb37 100644
--- a/nixos/modules/hardware/system-76.nix
+++ b/nixos/modules/hardware/system-76.nix
@@ -1,8 +1,9 @@
-{ config, lib, pkgs, ... }:
+{ config, lib, options, pkgs, ... }:
let
- inherit (lib) mkOption mkEnableOption types mkIf mkMerge optional versionOlder;
+ inherit (lib) literalExpression mkOption mkEnableOption types mkIf mkMerge optional versionOlder;
cfg = config.hardware.system76;
+ opt = options.hardware.system76;
kpkgs = config.boot.kernelPackages;
modules = [ "system76" "system76-io" ] ++ (optional (versionOlder kpkgs.kernel.version "5.5") "system76-acpi");
@@ -60,6 +61,7 @@ in {
firmware-daemon.enable = mkOption {
default = cfg.enableAll;
+ defaultText = literalExpression "config.${opt.enableAll}";
example = true;
description = "Whether to enable the system76 firmware daemon";
type = types.bool;
@@ -67,6 +69,7 @@ in {
kernel-modules.enable = mkOption {
default = cfg.enableAll;
+ defaultText = literalExpression "config.${opt.enableAll}";
example = true;
description = "Whether to make the system76 out-of-tree kernel modules available";
type = types.bool;
@@ -74,6 +77,7 @@ in {
power-daemon.enable = mkOption {
default = cfg.enableAll;
+ defaultText = literalExpression "config.${opt.enableAll}";
example = true;
description = "Whether to enable the system76 power daemon";
type = types.bool;
diff --git a/nixos/modules/misc/version.nix b/nixos/modules/misc/version.nix
index 8f246a9278b7..fc0d65d5148e 100644
--- a/nixos/modules/misc/version.nix
+++ b/nixos/modules/misc/version.nix
@@ -1,9 +1,10 @@
-{ config, lib, pkgs, ... }:
+{ config, lib, options, pkgs, ... }:
with lib;
let
cfg = config.system.nixos;
+ opt = options.system.nixos;
in
{
@@ -53,6 +54,7 @@ in
stateVersion = mkOption {
type = types.str;
default = cfg.release;
+ defaultText = liter