treewide: add bool type to enable options, or make use of mkEnableOption

Add missing type information to manually specified enable options or replace them by mkEnableOption where appropriate.
This commit is contained in:
Dominik Xaver Hörl
2020-04-21 08:55:36 +02:00
parent 3bbd074217
commit 0412bde942
59 changed files with 71 additions and 175 deletions
+1
View File
@@ -8,6 +8,7 @@ in {
options = { options = {
programs.cdemu = { programs.cdemu = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
<command>cdemu</command> for members of <command>cdemu</command> for members of
+1
View File
@@ -8,6 +8,7 @@ in {
options = { options = {
programs.criu = { programs.criu = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Install <command>criu</command> along with necessary kernel options. Install <command>criu</command> along with necessary kernel options.
+1
View File
@@ -8,6 +8,7 @@ in {
options = { options = {
programs.systemtap = { programs.systemtap = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Install <command>systemtap</command> along with necessary kernel options. Install <command>systemtap</command> along with necessary kernel options.
+1
View File
@@ -39,6 +39,7 @@ in
options = { options = {
programs.zsh.ohMyZsh = { programs.zsh.ohMyZsh = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Enable oh-my-zsh. Enable oh-my-zsh.
+1
View File
@@ -17,6 +17,7 @@ in {
options = { options = {
services.rabbitmq = { services.rabbitmq = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Whether to enable the RabbitMQ server, an Advanced Message Whether to enable the RabbitMQ server, an Advanced Message
@@ -37,12 +37,7 @@ in
services.mysqlBackup = { services.mysqlBackup = {
enable = mkOption { enable = mkEnableOption "MySQL backups";
default = false;
description = ''
Whether to enable MySQL backups.
'';
};
calendar = mkOption { calendar = mkOption {
type = types.str; type = types.str;
@@ -44,12 +44,7 @@ in {
options = { options = {
services.postgresqlBackup = { services.postgresqlBackup = {
enable = mkOption { enable = mkEnableOption "PostgreSQL dumps";
default = false;
description = ''
Whether to enable PostgreSQL dumps.
'';
};
startAt = mkOption { startAt = mkOption {
default = "*-*-* 01:15:00"; default = "*-*-* 01:15:00";
@@ -11,10 +11,7 @@ with lib;
services.clickhouse = { services.clickhouse = {
enable = mkOption { enable = mkEnableOption "ClickHouse database server";
default = false;
description = "Whether to enable ClickHouse database server.";
};
}; };
@@ -40,12 +40,7 @@ in
services.firebird = { services.firebird = {
enable = mkOption { enable = mkEnableOption "the Firebird super server";
default = false;
description = ''
Whether to enable the Firebird super server.
'';
};
package = mkOption { package = mkOption {
default = pkgs.firebirdSuper; default = pkgs.firebirdSuper;
@@ -18,12 +18,7 @@ in
services.memcached = { services.memcached = {
enable = mkOption { enable = mkEnableOption "Memcached";
default = false;
description = "
Whether to enable Memcached.
";
};
user = mkOption { user = mkOption {
default = "memcached"; default = "memcached";
+1 -6
View File
@@ -29,12 +29,7 @@ in
services.mongodb = { services.mongodb = {
enable = mkOption { enable = mkEnableOption "the MongoDB server";
default = false;
description = "
Whether to enable the MongoDB server.
";
};
package = mkOption { package = mkOption {
default = pkgs.mongodb; default = pkgs.mongodb;
@@ -13,10 +13,7 @@ with lib;
services.virtuoso = { services.virtuoso = {
enable = mkOption { enable = mkEnableOption "Virtuoso Opensource database server";
default = false;
description = "Whether to enable Virtuoso Opensource database server.";
};
config = mkOption { config = mkOption {
default = ""; default = "";
+1 -6
View File
@@ -10,12 +10,7 @@ in
options = { options = {
services.ratbagd = { services.ratbagd = {
enable = mkOption { enable = mkEnableOption "ratbagd for configuring gaming mice";
default = false;
description = ''
Whether to enable ratbagd for configuring gaming mice.
'';
};
}; };
}; };
+1 -6
View File
@@ -8,12 +8,7 @@ in {
###### interface ###### interface
options = { options = {
services.thermald = { services.thermald = {
enable = mkOption { enable = mkEnableOption "thermald, the temperature management daemon";
default = false;
description = ''
Whether to enable thermald, the temperature management daemon.
'';
};
debug = mkOption { debug = mkOption {
type = types.bool; type = types.bool;
+1 -4
View File
@@ -12,10 +12,7 @@ in
options = { options = {
services.spamassassin = { services.spamassassin = {
enable = mkOption { enable = mkEnableOption "the SpamAssassin daemon";
default = false;
description = "Whether to run the SpamAssassin daemon";
};
debug = mkOption { debug = mkOption {
default = false; default = false;
+1
View File
@@ -19,6 +19,7 @@ in
services.autofs = { services.autofs = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Mount filesystems on demand. Unmount them automatically. Mount filesystems on demand. Unmount them automatically.
+1 -7
View File
@@ -31,13 +31,7 @@ in
services.cgminer = { services.cgminer = {
enable = mkOption { enable = mkEnableOption "cgminer, an ASIC/FPGA/GPU miner for bitcoin and litecoin";
default = false;
description = ''
Whether to enable cgminer, an ASIC/FPGA/GPU miner for bitcoin and
litecoin.
'';
};
package = mkOption { package = mkOption {
default = pkgs.cgminer; default = pkgs.cgminer;
+1 -6
View File
@@ -8,12 +8,7 @@ let
in { in {
options = { options = {
services.devmon = { services.devmon = {
enable = mkOption { enable = mkEnableOption "devmon, an automatic device mounting daemon";
default = false;
description = ''
Whether to enable devmon, an automatic device mounting daemon.
'';
};
}; };
}; };
+1 -4
View File
@@ -17,10 +17,7 @@ in
services.disnix = { services.disnix = {
enable = mkOption { enable = mkEnableOption "Disnix";
default = false;
description = "Whether to enable Disnix";
};
enableMultiUser = mkOption { enableMultiUser = mkOption {
type = types.bool; type = types.bool;
+1 -4
View File
@@ -17,10 +17,7 @@ in
services.felix = { services.felix = {
enable = mkOption { enable = mkEnableOption "the Apache Felix OSGi service";
default = false;
description = "Whether to enable the Apache Felix OSGi service";
};
bundles = mkOption { bundles = mkOption {
type = types.listOf types.package; type = types.listOf types.package;
+1
View File
@@ -15,6 +15,7 @@ in
options = { options = {
services.ihaskell = { services.ihaskell = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = "Autostart an IHaskell notebook service."; description = "Autostart an IHaskell notebook service.";
}; };
+1 -4
View File
@@ -16,10 +16,7 @@ in
services.safeeyes = { services.safeeyes = {
enable = mkOption { enable = mkEnableOption "the safeeyes OSGi service";
default = false;
description = "Whether to enable the safeeyes OSGi service";
};
}; };
+1
View File
@@ -18,6 +18,7 @@ in
services.svnserve = { services.svnserve = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = "Whether to enable svnserve to serve Subversion repositories through the SVN protocol."; description = "Whether to enable svnserve to serve Subversion repositories through the SVN protocol.";
}; };
+4 -12
View File
@@ -19,12 +19,8 @@ in
# !!! All these option descriptions needs to be cleaned up. # !!! All these option descriptions needs to be cleaned up.
client = { client = {
enable = mkOption { enable = mkEnableOption "the Synergy client (receive keyboard and mouse events from a Synergy server)";
default = false;
description = "
Whether to enable the Synergy client (receive keyboard and mouse events from a Synergy server).
";
};
screenName = mkOption { screenName = mkOption {
default = ""; default = "";
description = '' description = ''
@@ -47,12 +43,8 @@ in
}; };
server = { server = {
enable = mkOption { enable = mkEnableOption "the Synergy server (send keyboard and mouse events)";
default = false;
description = ''
Whether to enable the Synergy server (send keyboard and mouse events).
'';
};
configFile = mkOption { configFile = mkOption {
default = "/etc/synergy-server.conf"; default = "/etc/synergy-server.conf";
description = "The Synergy server configuration file."; description = "The Synergy server configuration file.";
@@ -43,10 +43,7 @@ in
options = { options = {
services.netatalk = { services.netatalk = {
enable = mkOption { enable = mkEnableOption "the Netatalk AFP fileserver";
default = false;
description = "Whether to enable the Netatalk AFP fileserver.";
};
port = mkOption { port = mkOption {
default = 548; default = 548;
@@ -65,6 +62,7 @@ in
homes = { homes = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = "Enable sharing of the UNIX server user home directories."; description = "Enable sharing of the UNIX server user home directories.";
}; };
@@ -29,10 +29,7 @@ in
options = { options = {
services.rsyncd = { services.rsyncd = {
enable = mkOption { enable = mkEnableOption "the rsync daemon";
default = false;
description = "Whether to enable the rsync daemon.";
};
motd = mkOption { motd = mkOption {
type = types.str; type = types.str;
@@ -100,11 +100,13 @@ in
dir = { dir = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = true; default = true;
description = '' description = ''
Whether to enable XtreemFS DIR service. Whether to enable XtreemFS DIR service.
''; '';
}; };
uuid = mkOption { uuid = mkOption {
example = "eacb6bab-f444-4ebf-a06a-3f72d7465e40"; example = "eacb6bab-f444-4ebf-a06a-3f72d7465e40";
description = '' description = ''
@@ -218,11 +220,13 @@ in
mrc = { mrc = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = true; default = true;
description = '' description = ''
Whether to enable XtreemFS MRC service. Whether to enable XtreemFS MRC service.
''; '';
}; };
uuid = mkOption { uuid = mkOption {
example = "eacb6bab-f444-4ebf-a06a-3f72d7465e41"; example = "eacb6bab-f444-4ebf-a06a-3f72d7465e41";
description = '' description = ''
@@ -354,11 +358,13 @@ in
osd = { osd = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = true; default = true;
description = '' description = ''
Whether to enable XtreemFS OSD service. Whether to enable XtreemFS OSD service.
''; '';
}; };
uuid = mkOption { uuid = mkOption {
example = "eacb6bab-f444-4ebf-a06a-3f72d7465e42"; example = "eacb6bab-f444-4ebf-a06a-3f72d7465e42";
description = '' description = ''
@@ -21,6 +21,7 @@ in
services.yandex-disk = { services.yandex-disk = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = " description = "
Whether to enable Yandex-disk client. See https://disk.yandex.ru/ Whether to enable Yandex-disk client. See https://disk.yandex.ru/
@@ -16,6 +16,7 @@ in
services.amule = { services.amule = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Whether to run the AMule daemon. You need to manually run "amuled --ec-config" to configure the service for the first time. Whether to run the AMule daemon. You need to manually run "amuled --ec-config" to configure the service for the first time.
+1 -6
View File
@@ -35,12 +35,7 @@ in
services.babeld = { services.babeld = {
enable = mkOption { enable = mkEnableOption "the babeld network routing daemon";
default = false;
description = ''
Whether to run the babeld network routing daemon.
'';
};
interfaceDefaults = mkOption { interfaceDefaults = mkOption {
default = null; default = null;
+1 -6
View File
@@ -68,12 +68,7 @@ in
services.bind = { services.bind = {
enable = mkOption { enable = mkEnableOption "BIND domain name server";
default = false;
description = "
Whether to enable BIND domain name server.
";
};
cacheNetworks = mkOption { cacheNetworks = mkOption {
default = ["127.0.0.0/24"]; default = ["127.0.0.0/24"];
@@ -48,6 +48,7 @@ in
services.bitlbee = { services.bitlbee = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Whether to run the BitlBee IRC to other chat network gateway. Whether to run the BitlBee IRC to other chat network gateway.
+1 -6
View File
@@ -33,12 +33,7 @@ in
options.services.cntlm = { options.services.cntlm = {
enable = mkOption { enable = mkEnableOption "cntlm, which starts a local proxy";
default = false;
description = ''
Whether to enable the cntlm, which start a local proxy.
'';
};
username = mkOption { username = mkOption {
description = '' description = ''
@@ -39,6 +39,7 @@ in
services.flashpolicyd = { services.flashpolicyd = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = description =
'' ''
+2 -6
View File
@@ -42,12 +42,8 @@ in
{ {
options = { options = {
services.gvpe = { services.gvpe = {
enable = mkOption { enable = lib.mkEnableOption "gvpe";
default = false;
description = ''
Whether to run gvpe
'';
};
nodename = mkOption { nodename = mkOption {
default = null; default = null;
description ='' description =''
@@ -49,6 +49,7 @@ in
services.hostapd = { services.hostapd = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Enable putting a wireless interface into infrastructure mode, Enable putting a wireless interface into infrastructure mode,
@@ -36,12 +36,7 @@ in
services.ircdHybrid = { services.ircdHybrid = {
enable = mkOption { enable = mkEnableOption "IRCD";
default = false;
description = "
Enable IRCD.
";
};
serverName = mkOption { serverName = mkOption {
default = "hades.arpa"; default = "hades.arpa";
@@ -18,12 +18,8 @@ in
options = { options = {
services.mailpile = { services.mailpile = {
enable = mkOption { enable = mkEnableOption "Mailpile the mail client";
default = false;
description = "
Whether to enable Mailpile the mail client.
";
};
hostname = mkOption { hostname = mkOption {
default = "localhost"; default = "localhost";
description = "Listen to this hostname or ip."; description = "Listen to this hostname or ip.";
@@ -30,6 +30,7 @@ in
options = { options = {
services.chrony = { services.chrony = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Whether to synchronise your machine's time using chrony. Whether to synchronise your machine's time using chrony.
@@ -40,6 +40,7 @@ in
services.ntp = { services.ntp = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Whether to synchronise your machine's time using ntpd, as a peer in Whether to synchronise your machine's time using ntpd, as a peer in
@@ -9,12 +9,7 @@ with lib;
services.openfire = { services.openfire = {
enable = mkOption { enable = mkEnableOption "OpenFire XMPP server";
default = false;
description = "
Whether to enable OpenFire XMPP server.
";
};
usePostgreSQL = mkOption { usePostgreSQL = mkOption {
default = true; default = true;
+1 -6
View File
@@ -41,12 +41,7 @@ in
services.prayer = { services.prayer = {
enable = mkOption { enable = mkEnableOption "the prayer webmail http server";
default = false;
description = ''
Whether to run the prayer webmail http server.
'';
};
port = mkOption { port = mkOption {
default = "2080"; default = "2080";
@@ -16,12 +16,7 @@ in
services.quassel = { services.quassel = {
enable = mkOption { enable = mkEnableOption "the Quassel IRC client daemon";
default = false;
description = ''
Whether to run the Quassel IRC client daemon.
'';
};
certificateFile = mkOption { certificateFile = mkOption {
type = types.nullOr types.str; type = types.nullOr types.str;
@@ -19,6 +19,7 @@ in
options = { options = {
services.radvd.enable = mkOption { services.radvd.enable = mkOption {
type = types.bool;
default = false; default = false;
description = description =
'' ''
@@ -17,6 +17,7 @@ in
options = { options = {
services.rdnssd.enable = mkOption { services.rdnssd.enable = mkOption {
type = types.bool;
default = false; default = false;
#default = config.networking.enableIPv6; #default = config.networking.enableIPv6;
description = description =
@@ -15,10 +15,8 @@ in
options = { options = {
services.sabnzbd = { services.sabnzbd = {
enable = mkOption { enable = mkEnableOption "the sabnzbd server";
default = false;
description = "Whether to enable the sabnzbd server.";
};
configFile = mkOption { configFile = mkOption {
default = "/var/lib/sabnzbd/sabnzbd.ini"; default = "/var/lib/sabnzbd/sabnzbd.ini";
description = "Path to config file."; description = "Path to config file.";
@@ -17,6 +17,7 @@ in
services.shairport-sync = { services.shairport-sync = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Enable the shairport-sync daemon. Enable the shairport-sync daemon.
@@ -19,6 +19,7 @@ in
services.lshd = { services.lshd = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Whether to enable the GNU lshd SSH2 daemon, which allows Whether to enable the GNU lshd SSH2 daemon, which allows
+1 -6
View File
@@ -44,12 +44,7 @@ in
options = { options = {
services.xinetd.enable = mkOption { services.xinetd.enable = mkEnableOption "the xinetd super-server daemon";
default = false;
description = ''
Whether to enable the xinetd super-server daemon.
'';
};
services.xinetd.extraDefaults = mkOption { services.xinetd.extraDefaults = mkOption {
default = ""; default = "";
+1 -6
View File
@@ -10,12 +10,7 @@ in {
services.fprot = { services.fprot = {
updater = { updater = {
enable = mkOption { enable = mkEnableOption "automatic F-Prot virus definitions database updates";
default = false;
description = ''
Whether to enable automatic F-Prot virus definitions database updates.
'';
};
productData = mkOption { productData = mkOption {
description = '' description = ''
@@ -51,12 +51,7 @@ in
###### interface ###### interface
options = { options = {
services.kerberos_server = { services.kerberos_server = {
enable = mkOption { enable = lib.mkEnableOption "the kerberos authentification server";
default = false;
description = ''
Enable the kerberos authentification server.
'';
};
realms = mkOption { realms = mkOption {
type = types.attrsOf (types.submodule realm); type = types.attrsOf (types.submodule realm);
@@ -8,6 +8,7 @@ in {
options = { options = {
services.localtime = { services.localtime = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Enable <literal>localtime</literal>, simple daemon for keeping the system Enable <literal>localtime</literal>, simple daemon for keeping the system
@@ -10,6 +10,7 @@ in
options = { options = {
services.uptimed = { services.uptimed = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Enable <literal>uptimed</literal>, allowing you to track Enable <literal>uptimed</literal>, allowing you to track
@@ -24,6 +24,7 @@ in
services.jboss = { services.jboss = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = "Whether to enable JBoss. WARNING : this package is outdated and is known to have vulnerabilities."; description = "Whether to enable JBoss. WARNING : this package is outdated and is known to have vulnerabilities.";
}; };
@@ -23,6 +23,7 @@ in
options = { options = {
services.xserver.desktopManager.enlightenment.enable = mkOption { services.xserver.desktopManager.enlightenment.enable = mkOption {
type = types.bool;
default = false; default = false;
description = "Enable the Enlightenment desktop environment."; description = "Enable the Enlightenment desktop environment.";
}; };
@@ -72,6 +72,7 @@ in
services.xserver.desktopManager.gnome3 = { services.xserver.desktopManager.gnome3 = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = "Enable Gnome 3 desktop manager."; description = "Enable Gnome 3 desktop manager.";
}; };
@@ -10,6 +10,7 @@ in
options = { options = {
services.xserver.desktopManager.kodi = { services.xserver.desktopManager.kodi = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = "Enable the kodi multimedia center."; description = "Enable the kodi multimedia center.";
}; };
@@ -15,6 +15,7 @@ in
options = { options = {
services.xserver.displayManager.startx = { services.xserver.displayManager.startx = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Whether to enable the dummy "startx" pseudo-display manager, Whether to enable the dummy "startx" pseudo-display manager,
@@ -15,6 +15,7 @@ in
services.xserver.wacom = { services.xserver.wacom = {
enable = mkOption { enable = mkOption {
type = types.bool;
default = false; default = false;
description = '' description = ''
Whether to enable the Wacom touchscreen/digitizer/tablet. Whether to enable the Wacom touchscreen/digitizer/tablet.