Add missing 'type', 'defaultText' and 'literalExample' in module definitions
- add missing types in module definitions - add missing 'defaultText' in module definitions - wrap example with 'literalExample' where necessary in module definitions
···5757 users.ldap = {
58585959 enable = mkOption {
6060+ type = types.bool;
6061 default = false;
6162 description = "Whether to enable authentication against an LDAP server.";
6263 };
+1
nixos/modules/config/pulseaudio.nix
···9999 package = mkOption {
100100 type = types.package;
101101 default = pulseaudioLight;
102102+ defaultText = "pkgs.pulseaudioLight";
102103 example = literalExample "pkgs.pulseaudioFull";
103104 description = ''
104105 The PulseAudio derivation to use. This can be used to enable
···10101111 options = {
1212 environment.unixODBCDrivers = mkOption {
1313+ type = types.listOf types.package;
1314 default = [];
1414- example = literalExample "map (x : x.ini) (with pkgs.unixODBCDrivers; [ mysql psql psqlng ] )";
1515+ example = literalExample "with pkgs.unixODBCDrivers; [ mysql psql psqlng ]";
1516 description = ''
1617 Specifies Unix ODBC drivers to be registered in
1718 <filename>/etc/odbcinst.ini</filename>. You may also want to
···2627 config = mkIf (config.environment.unixODBCDrivers != []) {
27282829 environment.etc."odbcinst.ini".text =
2929- let inis = config.environment.unixODBCDrivers;
3030+ let inis = map (x : x.ini) config.environment.unixODBCDrivers;
3031 in lib.concatStringsSep "\n" inis;
31323233 };
+1
nixos/modules/misc/crashdump.nix
···2424 '';
2525 };
2626 kernelPackages = mkOption {
2727+ type = types.package;
2728 default = pkgs.linuxPackages;
2829 # We don't want to evaluate all of linuxPackages for the manual
2930 # - some of it might not even evaluate correctly.
+2-2
nixos/modules/misc/nixos.nix
···37373838 nixos.extraModules = mkOption {
3939 default = [];
4040- example = literalExample "mkIf config.services.openssh.enable [ ./sshd-config.nix ]";
4141- type = types.listOf types.unspecified;
4040+ example = literalExample "[ ./sshd-config.nix ]";
4141+ type = types.listOf (types.either (types.submodule ({...}:{options={};})) types.path);
4242 description = ''
4343 Define additional modules which would be loaded to evaluate the
4444 configuration.
···207207 description = ''
208208 Extra configuration to be passed in Client directive.
209209 '';
210210- example = literalExample ''
210210+ example = ''
211211 Maximum Concurrent Jobs = 20;
212212 Heartbeat Interval = 30;
213213 '';
···218218 description = ''
219219 Extra configuration to be passed in Messages directive.
220220 '';
221221- example = literalExample ''
221221+ example = ''
222222 console = all
223223 '';
224224 };
···9090 package = mkOption {
9191 type = types.package;
9292 default = pkgs.dovecot22;
9393+ defaultText = "pkgs.dovecot22";
9394 description = "Dovecot package to use.";
9495 };
9596···131132 modules = mkOption {
132133 type = types.listOf types.package;
133134 default = [];
134134- example = [ pkgs.dovecot_pigeonhole ];
135135+ example = literalExample "[ pkgs.dovecot_pigeonhole ]";
135136 description = ''
136137 Symlinks the contents of lib/dovecot of every given package into
137138 /var/lib/dovecot/modules. This will make the given modules available
+1-2
nixos/modules/services/misc/apache-kafka.nix
···118118119119 package = mkOption {
120120 description = "The kafka package to use";
121121-122121 default = pkgs.apacheKafka;
123123-122122+ defaultText = "pkgs.apacheKafka";
124123 type = types.package;
125124 };
126125
+2-1
nixos/modules/services/misc/autofs.nix
···2727 };
28282929 autoMaster = mkOption {
3030+ type = types.str;
3031 example = literalExample ''
3131- autoMaster = let
3232+ let
3233 mapConf = pkgs.writeText "auto" '''
3334 kernel -ro,soft,intr ftp.kernel.org:/pub/linux
3435 boot -fstype=ext2 :/dev/hda1
···108108 finders = mkOption {
109109 description = "List of finder plugins to load.";
110110 default = [];
111111- example = [ pkgs.python27Packages.graphite_influxdb ];
111111+ example = literalExample "[ pkgs.python27Packages.graphite_influxdb ]";
112112 type = types.listOf types.package;
113113 };
114114···136136 package = mkOption {
137137 description = "Package to use for graphite api.";
138138 default = pkgs.python27Packages.graphite_api;
139139+ defaultText = "pkgs.python27Packages.graphite_api";
139140 type = types.package;
140141 };
141142···146147 directories:
147148 - ${dataDir}/whisper
148149 '';
149149- example = literalExample ''
150150+ example = ''
150151 allowed_origins:
151152 - dashboard.example.com
152153 cheat_times: true
···350351 critical: 200
351352 name: Test
352353 '';
353353- example = literalExample ''
354354+ example = ''
354355 pushbullet_key: pushbullet_api_key
355356 alerts:
356357 - target: stats.seatgeek.app.deal_quality.venue_info_cache.hit
+1
nixos/modules/services/monitoring/heapster.nix
···3333 package = mkOption {
3434 description = "Package to use by heapster";
3535 default = pkgs.heapster;
3636+ defaultText = "pkgs.heapster";
3637 type = types.package;
3738 };
3839 };
+3-15
nixos/modules/services/monitoring/munin.nix
···122122 HTML output is in <filename>/var/www/munin/</filename>, configure your
123123 favourite webserver to serve static files.
124124 '';
125125- example = literalExample ''
126126- services = {
127127- munin-node.enable = true;
128128- munin-cron = {
129129- enable = true;
130130- hosts = '''
131131- [''${config.networking.hostName}]
132132- address localhost
133133- ''';
134134- extraGlobalConfig = '''
135135- contact.email.command mail -s "Munin notification for ''${var:host}" someone@example.com
136136- ''';
137137- };
138138- };
139139- '';
140125 };
141126142127 extraGlobalConfig = mkOption {
···146131 See <link xlink:href='http://munin-monitoring.org/wiki/munin.conf' />.
147132 Useful to setup notifications, see
148133 <link xlink:href='http://munin-monitoring.org/wiki/HowToContact' />
134134+ '';
135135+ example = ''
136136+ contact.email.command mail -s "Munin notification for ''${var:host}" someone@example.com
149137 '';
150138 };
151139
+6
nixos/modules/services/monitoring/nagios.nix
···9494 };
95959696 plugins = mkOption {
9797+ type = types.listOf types.package;
9798 default = [pkgs.nagiosPluginsOfficial pkgs.ssmtp];
9999+ defaultText = "[pkgs.nagiosPluginsOfficial pkgs.ssmtp]";
98100 description = "
99101 Packages to be added to the Nagios <envar>PATH</envar>.
100102 Typically used to add plugins, but can be anything.
···102104 };
103105104106 mainConfigFile = mkOption {
107107+ type = types.package;
105108 default = nagiosCfgFile;
109109+ defaultText = "nagiosCfgFile";
106110 description = "
107111 Derivation for the main configuration file of Nagios.
108112 ";
109113 };
110114111115 cgiConfigFile = mkOption {
116116+ type = types.package;
112117 default = nagiosCGICfgFile;
118118+ defaultText = "nagiosCGICfgFile";
113119 description = "
114120 Derivation for the configuration file of Nagios CGI scripts
115121 that can be used in web servers for running the Nagios web interface.
+2-1
nixos/modules/services/monitoring/scollector.nix
···4343 package = mkOption {
4444 type = types.package;
4545 default = pkgs.scollector;
4646+ defaultText = "pkgs.scollector";
4647 example = literalExample "pkgs.scollector";
4748 description = ''
4849 scollector binary to use.
···7778 collectors = mkOption {
7879 type = with types; attrsOf (listOf path);
7980 default = {};
8080- example = literalExample "{ 0 = [ \"\${postgresStats}/bin/collect-stats\" ]; }";
8181+ example = literalExample "{ \"0\" = [ \"\${postgresStats}/bin/collect-stats\" ]; }";
8182 description = ''
8283 An attribute set mapping the frequency of collection to a list of
8384 binaries that should be executed at that frequency. You can use "0"
···8585 package = mkOption {
8686 type = types.package;
8787 default = pkgs.samba;
8888- example = pkgs.samba4;
8888+ defaultText = "pkgs.samba";
8989+ example = literalExample "pkgs.samba4";
8990 description = ''
9091 Defines which package should be used for the samba server.
9192 '';
+2
nixos/modules/services/networking/bind.nix
···120120 };
121121122122 configFile = mkOption {
123123+ type = types.path;
123124 default = confFile;
125125+ defaultText = "confFile";
124126 description = "
125127 Overridable config file to use for named. By default, that
126128 generated by nixos.
+1
nixos/modules/services/networking/consul.nix
···118118 package = mkOption {
119119 description = "Package to use for consul-alerts.";
120120 default = pkgs.consul-alerts;
121121+ defaultText = "pkgs.consul-alerts";
121122 type = types.package;
122123 };
123124
+2-1
nixos/modules/services/networking/firewall.nix
···421421 };
422422423423 networking.firewall.extraPackages = mkOption {
424424+ type = types.listOf types.package;
424425 default = [ ];
425425- example = [ pkgs.ipset ];
426426+ example = literalExample "[ pkgs.ipset ]";
426427 description =
427428 ''
428429 Additional packages to be included in the environment of the system
···6767 theme = {
68686969 package = mkOption {
7070- type = types.path;
7070+ type = types.package;
7171 default = pkgs.gnome3.gnome_themes_standard;
7272+ defaultText = "pkgs.gnome3.gnome_themes_standard";
7273 description = ''
7374 The package path that contains the theme given in the name option.
7475 '';
···8788 iconTheme = {
88898990 package = mkOption {
9090- type = types.path;
9191+ type = types.package;
9192 default = pkgs.gnome3.defaultIconTheme;
9393+ defaultText = "pkgs.gnome3.defaultIconTheme";
9294 description = ''
9395 The package path that contains the icon theme given in the name option.
9496 '';
···69697070 greeter = {
7171 package = mkOption {
7272- type = types.path;
7272+ type = types.package;
7373 description = ''
7474 The LightDM greeter to login via. The package should be a directory
7575 containing a .desktop file matching the name in the 'name' option.
···8686 };
87878888 background = mkOption {
8989+ type = types.path;
8990 description = ''
9091 The background image or color to use.
9192 '';
···2020 options = {
21212222 boot.kernelPackages = mkOption {
2323+ type = types.packageSet;
2324 default = pkgs.linuxPackages;
2425 # We don't want to evaluate all of linuxPackages for the manual
2526 # - some of it might not even evaluate correctly.
···6364 };
64656566 boot.extraModulePackages = mkOption {
6666- type = types.listOf types.path;
6767+ type = types.listOf types.package;
6768 default = [];
6869 example = literalExample "[ pkgs.linuxPackages.nvidia_x11 ]";
6970 description = "A list of additional packages supplying kernel modules.";
···229229230230 boot.initrd.luks.devices = mkOption {
231231 default = [ ];
232232- example = [ { name = "luksroot"; device = "/dev/sda3"; preLVM = true; } ];
232232+ example = literalExample ''[ { name = "luksroot"; device = "/dev/sda3"; preLVM = true; } ]'';
233233 description = ''
234234 The list of devices that should be decrypted using LUKS before trying to mount the
235235 root partition. This works for both LVM-over-LUKS and LUKS-over-LVM setups.