···275 </listitem>
276 <listitem>
277 <para>
0000000278 <link xlink:href="https://sr.ht">sourcehut</link>, a
279 collection of tools useful for software development. Available
280 as
···275 </listitem>
276 <listitem>
277 <para>
278+ <link xlink:href="https://maddy.email">maddy</link>, a
279+ composable all-in-one mail server. Available as
280+ <link xlink:href="options.html#opt-services.maddy.enable">services.maddy</link>.
281+ </para>
282+ </listitem>
283+ <listitem>
284+ <para>
285 <link xlink:href="https://sr.ht">sourcehut</link>, a
286 collection of tools useful for software development. Available
287 as
+2
nixos/doc/manual/release-notes/rl-2111.section.md
···7475- [PeerTube](https://joinpeertube.org/), developed by Framasoft, is the free and decentralized alternative to video platforms. Available at [services.peertube](options.html#opt-services.peertube.enable).
760077- [sourcehut](https://sr.ht), a collection of tools useful for software development. Available as [services.sourcehut](options.html#opt-services.sourcehut.enable).
7879- [ucarp](https://download.pureftpd.org/pub/ucarp/README), an userspace implementation of the Common Address Redundancy Protocol (CARP). Available as [networking.ucarp](options.html#opt-networking.ucarp.enable).
···7475- [PeerTube](https://joinpeertube.org/), developed by Framasoft, is the free and decentralized alternative to video platforms. Available at [services.peertube](options.html#opt-services.peertube.enable).
7677+- [maddy](https://maddy.email), a composable all-in-one mail server. Available as [services.maddy](options.html#opt-services.maddy.enable).
78+79- [sourcehut](https://sr.ht), a collection of tools useful for software development. Available as [services.sourcehut](options.html#opt-services.sourcehut.enable).
8081- [ucarp](https://download.pureftpd.org/pub/ucarp/README), an userspace implementation of the Common Address Redundancy Protocol (CARP). Available as [networking.ucarp](options.html#opt-networking.ucarp.enable).
+36-14
nixos/lib/eval-config.nix
···8# as subcomponents (e.g. the container feature, or nixops if network
9# expressions are ever made modular at the top level) can just use
10# types.submodule instead of using eval-config.nix
011{ # !!! system can be set modularly, would be nice to remove
12 system ? builtins.currentSystem
13, # !!! is this argument needed any more? The pkgs argument can
···28 in if e == "" then [] else [(import e)]
29}:
3031-let extraArgs_ = extraArgs; pkgs_ = pkgs;
32in
3334let
···51 };
52 };
5354- noUserModules = lib.evalModules {
55- inherit prefix check;
56- modules = baseModules ++ extraModules ++ [ pkgsModule ];
57- args = extraArgs;
0000000000000000058 specialArgs =
59 { modulesPath = builtins.toString ../modules; } // specialArgs;
00000000060 };
6162- # These are the extra arguments passed to every module. In
63- # particular, Nixpkgs is passed through the "pkgs" argument.
64- extraArgs = extraArgs_ // {
65- inherit noUserModules baseModules extraModules modules;
66- };
6768-in rec {
6970 # Merge the option definitions in all modules, forming the full
71 # system configuration.
72- inherit (noUserModules.extendModules { inherit modules; })
73- config options _module type;
7475 inherit extraArgs;
7677- inherit (_module.args) pkgs;
78}
···8# as subcomponents (e.g. the container feature, or nixops if network
9# expressions are ever made modular at the top level) can just use
10# types.submodule instead of using eval-config.nix
11+evalConfigArgs@
12{ # !!! system can be set modularly, would be nice to remove
13 system ? builtins.currentSystem
14, # !!! is this argument needed any more? The pkgs argument can
···29 in if e == "" then [] else [(import e)]
30}:
3132+let pkgs_ = pkgs;
33in
3435let
···52 };
53 };
5455+ withWarnings = x:
56+ lib.warnIf (evalConfigArgs?args) "The extraArgs argument to eval-config.nix is deprecated. Please set config._module.args instead."
57+ lib.warnIf (evalConfigArgs?check) "The check argument to eval-config.nix is deprecated. Please set config._module.check instead."
58+ x;
59+60+ legacyModules =
61+ lib.optional (evalConfigArgs?args) {
62+ config = {
63+ _module.args = extraArgs;
64+ };
65+ }
66+ ++ lib.optional (evalConfigArgs?check) {
67+ config = {
68+ _module.check = lib.mkDefault check;
69+ };
70+ };
71+ allUserModules = modules ++ legacyModules;
72+73+ noUserModules = lib.evalModules ({
74+ inherit prefix;
75+ modules = baseModules ++ extraModules ++ [ pkgsModule modulesModule ];
76 specialArgs =
77 { modulesPath = builtins.toString ../modules; } // specialArgs;
78+ });
79+80+ # Extra arguments that are useful for constructing a similar configuration.
81+ modulesModule = {
82+ config = {
83+ _module.args = {
84+ inherit noUserModules baseModules extraModules modules;
85+ };
86+ };
87 };
8889+ nixosWithUserModules = noUserModules.extendModules { modules = allUserModules; };
00009091+in withWarnings {
9293 # Merge the option definitions in all modules, forming the full
94 # system configuration.
95+ inherit (nixosWithUserModules) config options _module type;
09697 inherit extraArgs;
9899+ inherit (nixosWithUserModules._module.args) pkgs;
100}
+7-13
nixos/modules/misc/documentation.nix
···1-{ config, lib, pkgs, baseModules, extraModules, modules, modulesPath, ... }:
23with lib;
4···67 cfg = config.documentation;
89- manualModules =
10- baseModules
11- # Modules for which to show options even when not imported
12- ++ [ ../virtualisation/qemu-vm.nix ]
13- ++ optionals cfg.nixos.includeAllModules (extraModules ++ modules);
1415 /* For the purpose of generating docs, evaluate options with each derivation
16 in `pkgs` (recursively) replaced by a fake with path "\${pkgs.attribute.path}".
···24 extraSources = cfg.nixos.extraModuleSources;
25 options =
26 let
27- scrubbedEval = evalModules {
28- modules = [ { nixpkgs.localSystem = config.nixpkgs.localSystem; } ] ++ manualModules;
29- args = (config._module.args) // { modules = [ ]; };
30- specialArgs = {
31- pkgs = scrubDerivations "pkgs" pkgs;
32- inherit modulesPath;
33- };
34 };
35 scrubDerivations = namePrefix: pkgSet: mapAttrs
36 (name: value:
···1+{ config, lib, pkgs, extendModules, noUserModules, ... }:
23with lib;
4···67 cfg = config.documentation;
89+ /* Modules for which to show options even when not imported. */
10+ extraDocModules = [ ../virtualisation/qemu-vm.nix ];
0001112 /* For the purpose of generating docs, evaluate options with each derivation
13 in `pkgs` (recursively) replaced by a fake with path "\${pkgs.attribute.path}".
···21 extraSources = cfg.nixos.extraModuleSources;
22 options =
23 let
24+ extendNixOS = if cfg.nixos.includeAllModules then extendModules else noUserModules.extendModules;
25+ scrubbedEval = extendNixOS {
26+ modules = extraDocModules;
27+ specialArgs.pkgs = scrubDerivations "pkgs" pkgs;
00028 };
29 scrubDerivations = namePrefix: pkgSet: mapAttrs
30 (name: value:
···325326 # Working directory will be /tmp
327 script = ''
328- set -euxo pipefail
0329330 # This reimplements the expiration date check, but without querying
331 # the acme server first. By doing this offline, we avoid errors
···437 visible = false;
438 default = "_mkMergedOptionModule";
439 };
00440441 webroot = mkOption {
442 type = types.nullOr types.str;
···615616 options = {
617 security.acme = {
00618619 validMinDays = mkOption {
620 type = types.int;
···325326 # Working directory will be /tmp
327 script = ''
328+ ${optionalString data.enableDebugLogs "set -x"}
329+ set -euo pipefail
330331 # This reimplements the expiration date check, but without querying
332 # the acme server first. By doing this offline, we avoid errors
···438 visible = false;
439 default = "_mkMergedOptionModule";
440 };
441+442+ enableDebugLogs = mkEnableOption "debug logging for this certificate" // { default = cfg.enableDebugLogs; };
443444 webroot = mkOption {
445 type = types.nullOr types.str;
···618619 options = {
620 security.acme = {
621+622+ enableDebugLogs = mkEnableOption "debug logging for all certificates by default" // { default = true; };
623624 validMinDays = mkOption {
625 type = types.int;
···27}:
2829let
30- version = "1.10.1";
3132 # build stimuli file for PGO build and the script to generate it
33 # independently of the foot's build, so we can cache the result
···99 owner = "dnkl";
100 repo = pname;
101 rev = version;
102- sha256 = "12n1v9by519fg40xvjf4v0g2phi08lcg0clz7rxs2i2xwlizz7nc";
103 };
104105 depsBuildBuild = [
···27}:
2829let
30+ version = "1.10.2";
3132 # build stimuli file for PGO build and the script to generate it
33 # independently of the foot's build, so we can cache the result
···99 owner = "dnkl";
100 repo = pname;
101 rev = version;
102+ sha256 = "00096c2m8pn4gpafvmg9lhyprwgnsis62bq4qmagnbb49bj5kr9v";
103 };
104105 depsBuildBuild = [