Merge master into haskell-updates
This commit is contained in:
commit
6b17188503
|
@ -31,6 +31,10 @@ function Code(elem)
|
|||
tag = 'command'
|
||||
elseif elem.attributes['role'] == 'option' then
|
||||
tag = 'option'
|
||||
elseif elem.attributes['role'] == 'var' then
|
||||
tag = 'varname'
|
||||
elseif elem.attributes['role'] == 'env' then
|
||||
tag = 'envar'
|
||||
end
|
||||
|
||||
if tag ~= nil then
|
||||
|
|
|
@ -58,8 +58,10 @@ Additional syntax extensions are available, though not all extensions can be use
|
|||
A few markups for other kinds of literals are also available:
|
||||
|
||||
- `` {command}`rm -rfi` `` turns into {command}`rm -rfi`
|
||||
- `` {option}`networking.useDHCP` `` turns into {option}`networking.useDHCP`
|
||||
- `` {env}`XDG_DATA_DIRS` `` turns into {env}`XDG_DATA_DIRS`
|
||||
- `` {file}`/etc/passwd` `` turns into {file}`/etc/passwd`
|
||||
- `` {option}`networking.useDHCP` `` turns into {option}`networking.useDHCP`
|
||||
- `` {var}`/etc/passwd` `` turns into {var}`/etc/passwd`
|
||||
|
||||
These literal kinds are used mostly in NixOS option documentation.
|
||||
|
||||
|
|
120
lib/modules.nix
120
lib/modules.nix
|
@ -163,84 +163,50 @@ rec {
|
|||
# TODO: Change the type of this option to a submodule with a
|
||||
# freeformType, so that individual arguments can be documented
|
||||
# separately
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Additional arguments passed to each module in addition to ones
|
||||
like <literal>lib</literal>, <literal>config</literal>,
|
||||
and <literal>pkgs</literal>, <literal>modulesPath</literal>.
|
||||
</para>
|
||||
<para>
|
||||
like `lib`, `config`,
|
||||
and `pkgs`, `modulesPath`.
|
||||
|
||||
This option is also available to all submodules. Submodules do not
|
||||
inherit args from their parent module, nor do they provide args to
|
||||
their parent module or sibling submodules. The sole exception to
|
||||
this is the argument <literal>name</literal> which is provided by
|
||||
this is the argument `name` which is provided by
|
||||
parent modules to a submodule and contains the attribute name
|
||||
the submodule is bound to, or a unique generated name if it is
|
||||
not bound to an attribute.
|
||||
</para>
|
||||
<para>
|
||||
|
||||
Some arguments are already passed by default, of which the
|
||||
following <emphasis>cannot</emphasis> be changed with this option:
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>
|
||||
<varname>lib</varname>: The nixpkgs library.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<varname>config</varname>: The results of all options after merging the values from all modules together.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<varname>options</varname>: The options declared in all modules.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<varname>specialArgs</varname>: The <literal>specialArgs</literal> argument passed to <literal>evalModules</literal>.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
All attributes of <varname>specialArgs</varname>
|
||||
</para>
|
||||
<para>
|
||||
Whereas option values can generally depend on other option values
|
||||
thanks to laziness, this does not apply to <literal>imports</literal>, which
|
||||
must be computed statically before anything else.
|
||||
</para>
|
||||
<para>
|
||||
For this reason, callers of the module system can provide <literal>specialArgs</literal>
|
||||
which are available during import resolution.
|
||||
</para>
|
||||
<para>
|
||||
For NixOS, <literal>specialArgs</literal> includes
|
||||
<varname>modulesPath</varname>, which allows you to import
|
||||
extra modules from the nixpkgs package tree without having to
|
||||
somehow make the module aware of the location of the
|
||||
<literal>nixpkgs</literal> or NixOS directories.
|
||||
<programlisting>
|
||||
{ modulesPath, ... }: {
|
||||
imports = [
|
||||
(modulesPath + "/profiles/minimal.nix")
|
||||
];
|
||||
}
|
||||
</programlisting>
|
||||
</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</para>
|
||||
<para>
|
||||
following *cannot* be changed with this option:
|
||||
- {var}`lib`: The nixpkgs library.
|
||||
- {var}`config`: The results of all options after merging the values from all modules together.
|
||||
- {var}`options`: The options declared in all modules.
|
||||
- {var}`specialArgs`: The `specialArgs` argument passed to `evalModules`.
|
||||
- All attributes of {var}`specialArgs`
|
||||
|
||||
Whereas option values can generally depend on other option values
|
||||
thanks to laziness, this does not apply to `imports`, which
|
||||
must be computed statically before anything else.
|
||||
|
||||
For this reason, callers of the module system can provide `specialArgs`
|
||||
which are available during import resolution.
|
||||
|
||||
For NixOS, `specialArgs` includes
|
||||
{var}`modulesPath`, which allows you to import
|
||||
extra modules from the nixpkgs package tree without having to
|
||||
somehow make the module aware of the location of the
|
||||
`nixpkgs` or NixOS directories.
|
||||
```
|
||||
{ modulesPath, ... }: {
|
||||
imports = [
|
||||
(modulesPath + "/profiles/minimal.nix")
|
||||
];
|
||||
}
|
||||
```
|
||||
|
||||
For NixOS, the default value for this option includes at least this argument:
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>
|
||||
<varname>pkgs</varname>: The nixpkgs package set according to
|
||||
the <option>nixpkgs.pkgs</option> option.
|
||||
</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
- {var}`pkgs`: The nixpkgs package set according to
|
||||
the {option}`nixpkgs.pkgs` option.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -248,21 +214,21 @@ rec {
|
|||
type = types.bool;
|
||||
internal = true;
|
||||
default = true;
|
||||
description = "Whether to check whether all option definitions have matching declarations.";
|
||||
description = lib.mdDoc "Whether to check whether all option definitions have matching declarations.";
|
||||
};
|
||||
|
||||
_module.freeformType = mkOption {
|
||||
type = types.nullOr types.optionType;
|
||||
internal = true;
|
||||
default = null;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
If set, merge all definitions that don't have an associated option
|
||||
together using this type. The result then gets combined with the
|
||||
values of all declared options to produce the final <literal>
|
||||
config</literal> value.
|
||||
values of all declared options to produce the final `
|
||||
config` value.
|
||||
|
||||
If this is <literal>null</literal>, definitions without an option
|
||||
will throw an error unless <option>_module.check</option> is
|
||||
If this is `null`, definitions without an option
|
||||
will throw an error unless {option}`_module.check` is
|
||||
turned off.
|
||||
'';
|
||||
};
|
||||
|
@ -270,7 +236,7 @@ rec {
|
|||
_module.specialArgs = mkOption {
|
||||
readOnly = true;
|
||||
internal = true;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Externally provided module arguments that can't be modified from
|
||||
within a configuration, but can be used in module imports.
|
||||
'';
|
||||
|
@ -1169,7 +1135,7 @@ rec {
|
|||
{
|
||||
options = setAttrByPath from (mkOption {
|
||||
inherit visible;
|
||||
description = "Alias of <option>${showOption to}</option>.";
|
||||
description = lib.mdDoc "Alias of {option}`${showOption to}`.";
|
||||
apply = x: use (toOf config);
|
||||
} // optionalAttrs (toType != null) {
|
||||
type = toType;
|
||||
|
|
|
@ -95,7 +95,10 @@ rec {
|
|||
name: mkOption {
|
||||
default = false;
|
||||
example = true;
|
||||
description = "Whether to enable ${name}.";
|
||||
description =
|
||||
if name ? _type && name._type == "mdDoc"
|
||||
then lib.mdDoc "Whether to enable ${name.text}."
|
||||
else "Whether to enable ${name}.";
|
||||
type = lib.types.bool;
|
||||
};
|
||||
|
||||
|
@ -134,7 +137,7 @@ rec {
|
|||
let default' = if !isList default then [ default ] else default;
|
||||
in mkOption {
|
||||
type = lib.types.package;
|
||||
description = "The ${name} package to use.";
|
||||
description = lib.mdDoc "The ${name} package to use.";
|
||||
default = attrByPath default'
|
||||
(throw "${concatStringsSep "." default'} cannot be found in pkgs") pkgs;
|
||||
defaultText = literalExpression ("pkgs." + concatStringsSep "." default');
|
||||
|
|
|
@ -15130,4 +15130,14 @@
|
|||
fingerprint = "1147 43F1 E707 6F3E 6F4B 2C96 B9A8 B592 F126 F8E8";
|
||||
}];
|
||||
};
|
||||
tjni = {
|
||||
email = "43ngvg@masqt.com";
|
||||
matrix = "@tni:matrix.org";
|
||||
name = "Theodore Ni";
|
||||
github = "tjni";
|
||||
githubId = 3806110;
|
||||
keys = [{
|
||||
fingerprint = "4384 B8E1 299F C028 1641 7B8F EC30 EFBE FA7E 84A4";
|
||||
}];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -114,6 +114,10 @@ class Renderer(mistune.renderers.BaseRenderer):
|
|||
return f"<option>{escape(text)}</option>"
|
||||
def file(self, text):
|
||||
return f"<filename>{escape(text)}</filename>"
|
||||
def var(self, text):
|
||||
return f"<varname>{escape(text)}</varname>"
|
||||
def env(self, text):
|
||||
return f"<envar>{escape(text)}</envar>"
|
||||
def manpage(self, page, section):
|
||||
title = f"<refentrytitle>{escape(page)}</refentrytitle>"
|
||||
vol = f"<manvolnum>{escape(section)}</manvolnum>"
|
||||
|
@ -136,6 +140,20 @@ def p_file(md):
|
|||
md.inline.register_rule('file', FILE_PATTERN, parse)
|
||||
md.inline.rules.append('file')
|
||||
|
||||
def p_var(md):
|
||||
VAR_PATTERN = r'\{var\}`(.*?)`'
|
||||
def parse(self, m, state):
|
||||
return ('var', m.group(1))
|
||||
md.inline.register_rule('var', VAR_PATTERN, parse)
|
||||
md.inline.rules.append('var')
|
||||
|
||||
def p_env(md):
|
||||
ENV_PATTERN = r'\{env\}`(.*?)`'
|
||||
def parse(self, m, state):
|
||||
return ('env', m.group(1))
|
||||
md.inline.register_rule('env', ENV_PATTERN, parse)
|
||||
md.inline.rules.append('env')
|
||||
|
||||
def p_option(md):
|
||||
OPTION_PATTERN = r'\{option\}`(.*?)`'
|
||||
def parse(self, m, state):
|
||||
|
@ -162,7 +180,7 @@ def p_admonition(md):
|
|||
md.block.rules.append('admonition')
|
||||
|
||||
md = mistune.create_markdown(renderer=Renderer(), plugins=[
|
||||
p_command, p_file, p_option, p_manpage, p_admonition
|
||||
p_command, p_file, p_var, p_env, p_option, p_manpage, p_admonition
|
||||
])
|
||||
|
||||
# converts in-place!
|
||||
|
|
|
@ -37,11 +37,11 @@ rec {
|
|||
|
||||
initrdContents = types.attrsOf (types.submodule ({ config, options, name, ... }: {
|
||||
options = {
|
||||
enable = mkEnableOption "copying of this file and symlinking it" // { default = true; };
|
||||
enable = mkEnableOption (lib.mdDoc "copying of this file and symlinking it") // { default = true; };
|
||||
|
||||
target = mkOption {
|
||||
type = types.path;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Path of the symlink.
|
||||
'';
|
||||
default = name;
|
||||
|
@ -50,12 +50,12 @@ rec {
|
|||
text = mkOption {
|
||||
default = null;
|
||||
type = types.nullOr types.lines;
|
||||
description = "Text of the file.";
|
||||
description = lib.mdDoc "Text of the file.";
|
||||
};
|
||||
|
||||
source = mkOption {
|
||||
type = types.path;
|
||||
description = "Path of the source file.";
|
||||
description = lib.mdDoc "Path of the source file.";
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -37,24 +37,24 @@ in rec {
|
|||
enable = mkOption {
|
||||
default = true;
|
||||
type = types.bool;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
If set to false, this unit will be a symlink to
|
||||
/dev/null. This is primarily useful to prevent specific
|
||||
template instances
|
||||
(e.g. <literal>serial-getty@ttyS0</literal>) from being
|
||||
started. Note that <literal>enable=true</literal> does not
|
||||
(e.g. `serial-getty@ttyS0`) from being
|
||||
started. Note that `enable=true` does not
|
||||
make a unit start by default at boot; if you want that, see
|
||||
<literal>wantedBy</literal>.
|
||||
`wantedBy`.
|
||||
'';
|
||||
};
|
||||
|
||||
requiredBy = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Units that require (i.e. depend on and need to go down with)
|
||||
this unit. The discussion under <literal>wantedBy</literal>
|
||||
applies here as well: inverse <literal>.requires</literal>
|
||||
this unit. The discussion under `wantedBy`
|
||||
applies here as well: inverse `.requires`
|
||||
symlinks are established.
|
||||
'';
|
||||
};
|
||||
|
@ -62,16 +62,16 @@ in rec {
|
|||
wantedBy = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Units that want (i.e. depend on) this unit. The standard way
|
||||
to make a unit start by default at boot is to set this option
|
||||
to <literal>[ "multi-user.target" ]</literal>. That's despite
|
||||
to `[ "multi-user.target" ]`. That's despite
|
||||
the fact that the systemd.unit(5) manpage says this option
|
||||
goes in the <literal>[Install]</literal> section that controls
|
||||
the behaviour of <literal>systemctl enable</literal>. Since
|
||||
goes in the `[Install]` section that controls
|
||||
the behaviour of `systemctl enable`. Since
|
||||
such a process is stateful and thus contrary to the design of
|
||||
NixOS, setting this option instead causes the equivalent
|
||||
inverse <literal>.wants</literal> symlink to be present,
|
||||
inverse `.wants` symlink to be present,
|
||||
establishing the same desired relationship in a stateless way.
|
||||
'';
|
||||
};
|
||||
|
@ -79,7 +79,7 @@ in rec {
|
|||
aliases = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = "Aliases of that unit.";
|
||||
description = lib.mdDoc "Aliases of that unit.";
|
||||
};
|
||||
|
||||
};
|
||||
|
@ -89,12 +89,12 @@ in rec {
|
|||
text = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
description = "Text of this systemd unit.";
|
||||
description = lib.mdDoc "Text of this systemd unit.";
|
||||
};
|
||||
|
||||
unit = mkOption {
|
||||
internal = true;
|
||||
description = "The generated unit.";
|
||||
description = lib.mdDoc "The generated unit.";
|
||||
};
|
||||
|
||||
};
|
||||
|
@ -105,19 +105,19 @@ in rec {
|
|||
description = mkOption {
|
||||
default = "";
|
||||
type = types.singleLineStr;
|
||||
description = "Description of this unit used in systemd messages and progress indicators.";
|
||||
description = lib.mdDoc "Description of this unit used in systemd messages and progress indicators.";
|
||||
};
|
||||
|
||||
documentation = mkOption {
|
||||
default = [];
|
||||
type = types.listOf types.str;
|
||||
description = "A list of URIs referencing documentation for this unit or its configuration.";
|
||||
description = lib.mdDoc "A list of URIs referencing documentation for this unit or its configuration.";
|
||||
};
|
||||
|
||||
requires = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Start the specified units when this unit is started, and stop
|
||||
this unit when the specified units are stopped or fail.
|
||||
'';
|
||||
|
@ -126,7 +126,7 @@ in rec {
|
|||
wants = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Start the specified units when this unit is started.
|
||||
'';
|
||||
};
|
||||
|
@ -134,7 +134,7 @@ in rec {
|
|||
after = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
If the specified units are started at the same time as
|
||||
this unit, delay this unit until they have started.
|
||||
'';
|
||||
|
@ -143,7 +143,7 @@ in rec {
|
|||
before = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
If the specified units are started at the same time as
|
||||
this unit, delay them until this unit has started.
|
||||
'';
|
||||
|
@ -152,7 +152,7 @@ in rec {
|
|||
bindsTo = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Like ‘requires’, but in addition, if the specified units
|
||||
unexpectedly disappear, this unit will be stopped as well.
|
||||
'';
|
||||
|
@ -161,7 +161,7 @@ in rec {
|
|||
partOf = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
If the specified units are stopped or restarted, then this
|
||||
unit is stopped or restarted as well.
|
||||
'';
|
||||
|
@ -170,7 +170,7 @@ in rec {
|
|||
conflicts = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
If the specified units are started, then this unit is stopped
|
||||
and vice versa.
|
||||
'';
|
||||
|
@ -179,7 +179,7 @@ in rec {
|
|||
requisite = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Similar to requires. However if the units listed are not started,
|
||||
they will not be started and the transaction will fail.
|
||||
'';
|
||||
|
@ -189,18 +189,17 @@ in rec {
|
|||
default = {};
|
||||
example = { RequiresMountsFor = "/data"; };
|
||||
type = types.attrsOf unitOption;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Each attribute in this set specifies an option in the
|
||||
<literal>[Unit]</literal> section of the unit. See
|
||||
<citerefentry><refentrytitle>systemd.unit</refentrytitle>
|
||||
<manvolnum>5</manvolnum></citerefentry> for details.
|
||||
`[Unit]` section of the unit. See
|
||||
{manpage}`systemd.unit(5)` for details.
|
||||
'';
|
||||
};
|
||||
|
||||
onFailure = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
A list of one or more units that are activated when
|
||||
this unit enters the "failed" state.
|
||||
'';
|
||||
|
@ -209,7 +208,7 @@ in rec {
|
|||
onSuccess = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitNameType;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
A list of one or more units that are activated when
|
||||
this unit enters the "inactive" state.
|
||||
'';
|
||||
|
@ -217,7 +216,7 @@ in rec {
|
|||
|
||||
startLimitBurst = mkOption {
|
||||
type = types.int;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Configure unit start rate limiting. Units which are started
|
||||
more than startLimitBurst times within an interval time
|
||||
interval are not permitted to start any more.
|
||||
|
@ -226,7 +225,7 @@ in rec {
|
|||
|
||||
startLimitIntervalSec = mkOption {
|
||||
type = types.int;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Configure unit start rate limiting. Units which are started
|
||||
more than startLimitBurst times within an interval time
|
||||
interval are not permitted to start any more.
|
||||
|
@ -245,7 +244,7 @@ in rec {
|
|||
restartTriggers = mkOption {
|
||||
default = [];
|
||||
type = types.listOf types.unspecified;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
An arbitrary list of items such as derivations. If any item
|
||||
in the list changes between reconfigurations, the service will
|
||||
be restarted.
|
||||
|
@ -255,7 +254,7 @@ in rec {
|
|||
reloadTriggers = mkOption {
|
||||
default = [];
|
||||
type = types.listOf unitOption;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
An arbitrary list of items such as derivations. If any item
|
||||
in the list changes between reconfigurations, the service will
|
||||
be reloaded. If anything but a reload trigger changes in the
|
||||
|
@ -273,16 +272,16 @@ in rec {
|
|||
default = {};
|
||||
type = with types; attrsOf (nullOr (oneOf [ str path package ]));
|
||||
example = { PATH = "/foo/bar/bin"; LANG = "nl_NL.UTF-8"; };
|
||||
description = "Environment variables passed to the service's processes.";
|
||||
description = lib.mdDoc "Environment variables passed to the service's processes.";
|
||||
};
|
||||
|
||||
path = mkOption {
|
||||
default = [];
|
||||
type = with types; listOf (oneOf [ package str ]);
|
||||
description = ''
|
||||
Packages added to the service's <envar>PATH</envar>
|
||||
environment variable. Both the <filename>bin</filename>
|
||||
and <filename>sbin</filename> subdirectories of each
|
||||
description = lib.mdDoc ''
|
||||
Packages added to the service's {env}`PATH`
|
||||
environment variable. Both the {file}`bin`
|
||||
and {file}`sbin` subdirectories of each
|
||||
package are added.
|
||||
'';
|
||||
};
|
||||
|
@ -293,30 +292,29 @@ in rec {
|
|||
{ RestartSec = 5;
|
||||
};
|
||||
type = types.addCheck (types.attrsOf unitOption) checkService;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Each attribute in this set specifies an option in the
|
||||
<literal>[Service]</literal> section of the unit. See
|
||||
<citerefentry><refentrytitle>systemd.service</refentrytitle>
|
||||
<manvolnum>5</manvolnum></citerefentry> for details.
|
||||
`[Service]` section of the unit. See
|
||||
{manpage}`systemd.service(5)` for details.
|
||||
'';
|
||||
};
|
||||
|
||||
script = mkOption {
|
||||
type = types.lines;
|
||||
default = "";
|
||||
description = "Shell commands executed as the service's main process.";
|
||||
description = lib.mdDoc "Shell commands executed as the service's main process.";
|
||||
};
|
||||
|
||||
scriptArgs = mkOption {
|
||||
type = types.str;
|
||||
default = "";
|
||||
description = "Arguments passed to the main process script.";
|
||||
description = lib.mdDoc "Arguments passed to the main process script.";
|
||||
};
|
||||
|
||||
preStart = mkOption {
|
||||
type = types.lines;
|
||||
default = "";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Shell commands executed before the service's main process
|
||||
is started.
|
||||
'';
|
||||
|
@ -325,7 +323,7 @@ in rec {
|
|||
postStart = mkOption {
|
||||
type = types.lines;
|
||||
default = "";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Shell commands executed after the service's main process
|
||||
is started.
|
||||
'';
|
||||
|
@ -334,7 +332,7 @@ in rec {
|
|||
reload = mkOption {
|
||||
type = types.lines;
|
||||
default = "";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Shell commands executed when the service's main process
|
||||
is reloaded.
|
||||
'';
|
||||
|
@ -343,7 +341,7 @@ in rec {
|
|||
preStop = mkOption {
|
||||
type = types.lines;
|
||||
default = "";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Shell commands executed to stop the service.
|
||||
'';
|
||||
};
|
||||
|
@ -351,7 +349,7 @@ in rec {
|
|||
postStop = mkOption {
|
||||
type = types.lines;
|
||||
default = "";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Shell commands executed after the service's main process
|
||||
has exited.
|
||||
'';
|
||||
|
@ -360,7 +358,7 @@ in rec {
|
|||
jobScripts = mkOption {
|
||||
type = with types; coercedTo path singleton (listOf path);
|
||||
internal = true;
|
||||
description = "A list of all job script derivations of this unit.";
|
||||
description = lib.mdDoc "A list of all job script derivations of this unit.";
|
||||
default = [];
|
||||
};
|
||||
|
||||
|
@ -405,7 +403,7 @@ in rec {
|
|||
restartIfChanged = mkOption {
|
||||
type = types.bool;
|
||||
default = true;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Whether the service should be restarted during a NixOS
|
||||
configuration switch if its definition has changed.
|
||||
'';
|
||||
|
@ -414,14 +412,14 @@ in rec {
|
|||
reloadIfChanged = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Whether the service should be reloaded during a NixOS
|
||||
configuration switch if its definition has changed. If
|
||||
enabled, the value of <option>restartIfChanged</option> is
|
||||
enabled, the value of {option}`restartIfChanged` is
|
||||
ignored.
|
||||
|
||||
This option should not be used anymore in favor of
|
||||
<option>reloadTriggers</option> which allows more granular
|
||||
{option}`reloadTriggers` which allows more granular
|
||||
control of when a service is reloaded and when a service
|
||||
is restarted.
|
||||
'';
|
||||
|
@ -430,14 +428,14 @@ in rec {
|
|||
stopIfChanged = mkOption {
|
||||
type = types.bool;
|
||||
default = true;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
If set, a changed unit is restarted by calling
|
||||
<command>systemctl stop</command> in the old configuration,
|
||||
then <command>systemctl start</command> in the new one.
|
||||
{command}`systemctl stop` in the old configuration,
|
||||
then {command}`systemctl start` in the new one.
|
||||
Otherwise, it is restarted in a single step using
|
||||
<command>systemctl restart</command> in the new configuration.
|
||||
{command}`systemctl restart` in the new configuration.
|
||||
The latter is less correct because it runs the
|
||||
<literal>ExecStop</literal> commands from the new
|
||||
`ExecStop` commands from the new
|
||||
configuration.
|
||||
'';
|
||||
};
|
||||
|
@ -446,13 +444,12 @@ in rec {
|
|||
type = with types; either str (listOf str);
|
||||
default = [];
|
||||
example = "Sun 14:00:00";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Automatically start this unit at the given date/time, which
|
||||
must be in the format described in
|
||||
<citerefentry><refentrytitle>systemd.time</refentrytitle>
|
||||
<manvolnum>7</manvolnum></citerefentry>. This is equivalent
|
||||
{manpage}`systemd.time(7)`. This is equivalent
|
||||
to adding a corresponding timer unit with
|
||||
<option>OnCalendar</option> set to the value given here.
|
||||
{option}`OnCalendar` set to the value given here.
|
||||
'';
|
||||
apply = v: if isList v then v else [ v ];
|
||||
};
|
||||
|
@ -474,9 +471,9 @@ in rec {
|
|||
default = [];
|
||||
type = types.listOf types.str;
|
||||
example = [ "0.0.0.0:993" "/run/my-socket" ];
|
||||
description = ''
|
||||
For each item in this list, a <literal>ListenStream</literal>
|
||||
option in the <literal>[Socket]</literal> section will be created.
|
||||
description = lib.mdDoc ''
|
||||
For each item in this list, a `ListenStream`
|
||||
option in the `[Socket]` section will be created.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -484,9 +481,9 @@ in rec {
|
|||
default = [];
|
||||
type = types.listOf types.str;
|
||||
example = [ "0.0.0.0:993" "/run/my-socket" ];
|
||||
description = ''
|
||||
For each item in this list, a <literal>ListenDatagram</literal>
|
||||
option in the <literal>[Socket]</literal> section will be created.
|
||||
description = lib.mdDoc ''
|
||||
For each item in this list, a `ListenDatagram`
|
||||
option in the `[Socket]` section will be created.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -494,11 +491,10 @@ in rec {
|
|||
default = {};
|
||||
example = { ListenStream = "/run/my-socket"; };
|
||||
type = types.attrsOf unitOption;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Each attribute in this set specifies an option in the
|
||||
<literal>[Socket]</literal> section of the unit. See
|
||||
<citerefentry><refentrytitle>systemd.socket</refentrytitle>
|
||||
<manvolnum>5</manvolnum></citerefentry> for details.
|
||||
`[Socket]` section of the unit. See
|
||||
{manpage}`systemd.socket(5)` for details.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
@ -527,13 +523,11 @@ in rec {
|
|||
default = {};
|
||||
example = { OnCalendar = "Sun 14:00:00"; Unit = "foo.service"; };
|
||||
type = types.attrsOf unitOption;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Each attribute in this set specifies an option in the
|
||||
<literal>[Timer]</literal> section of the unit. See
|
||||
<citerefentry><refentrytitle>systemd.timer</refentrytitle>
|
||||
<manvolnum>5</manvolnum></citerefentry> and
|
||||
<citerefentry><refentrytitle>systemd.time</refentrytitle>
|
||||
<manvolnum>7</manvolnum></citerefentry> for details.
|
||||
`[Timer]` section of the unit. See
|
||||
{manpage}`systemd.timer(5)` and
|
||||
{manpage}`systemd.time(7)` for details.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -562,11 +556,10 @@ in rec {
|
|||
default = {};
|
||||
example = { PathChanged = "/some/path"; Unit = "changedpath.service"; };
|
||||
type = types.attrsOf unitOption;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Each attribute in this set specifies an option in the
|
||||
<literal>[Path]</literal> section of the unit. See
|
||||
<citerefentry><refentrytitle>systemd.path</refentrytitle>
|
||||
<manvolnum>5</manvolnum></citerefentry> for details.
|
||||
`[Path]` section of the unit. See
|
||||
{manpage}`systemd.path(5)` for details.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -594,13 +587,13 @@ in rec {
|
|||
what = mkOption {
|
||||
example = "/dev/sda1";
|
||||
type = types.str;
|
||||
description = "Absolute path of device node, file or other resource. (Mandatory)";
|
||||
description = lib.mdDoc "Absolute path of device node, file or other resource. (Mandatory)";
|
||||
};
|
||||
|
||||
where = mkOption {
|
||||
example = "/mnt";
|
||||
type = types.str;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Absolute path of a directory of the mount point.
|
||||
Will be created if it doesn't exist. (Mandatory)
|
||||
'';
|
||||
|
@ -610,25 +603,24 @@ in rec {
|
|||
default = "";
|
||||
example = "ext4";
|
||||
type = types.str;
|
||||
description = "File system type.";
|
||||
description = lib.mdDoc "File system type.";
|
||||
};
|
||||
|
||||
options = mkOption {
|
||||
default = "";
|
||||
example = "noatime";
|
||||
type = types.commas;
|
||||
description = "Options used to mount the file system.";
|
||||
description = lib.mdDoc "Options used to mount the file system.";
|
||||
};
|
||||
|
||||
mountConfig = mkOption {
|
||||
default = {};
|
||||
example = { DirectoryMode = "0775"; };
|
||||
type = types.attrsOf unitOption;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Each attribute in this set specifies an option in the
|
||||
<literal>[Mount]</literal> section of the unit. See
|
||||
<citerefentry><refentrytitle>systemd.mount</refentrytitle>
|
||||
<manvolnum>5</manvolnum></citerefentry> for details.
|
||||
`[Mount]` section of the unit. See
|
||||
{manpage}`systemd.mount(5)` for details.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -655,7 +647,7 @@ in rec {
|
|||
where = mkOption {
|
||||
example = "/mnt";
|
||||
type = types.str;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Absolute path of a directory of the mount point.
|
||||
Will be created if it doesn't exist. (Mandatory)
|
||||
'';
|
||||
|
@ -665,11 +657,10 @@ in rec {
|
|||
default = {};
|
||||
example = { DirectoryMode = "0775"; };
|
||||
type = types.attrsOf unitOption;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Each attribute in this set specifies an option in the
|
||||
<literal>[Automount]</literal> section of the unit. See
|
||||
<citerefentry><refentrytitle>systemd.automount</refentrytitle>
|
||||
<manvolnum>5</manvolnum></citerefentry> for details.
|
||||
`[Automount]` section of the unit. See
|
||||
{manpage}`systemd.automount(5)` for details.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -697,11 +688,10 @@ in rec {
|
|||
default = {};
|
||||
example = { MemoryMax = "2G"; };
|
||||
type = types.attrsOf unitOption;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Each attribute in this set specifies an option in the
|
||||
<literal>[Slice]</literal> section of the unit. See
|
||||
<citerefentry><refentrytitle>systemd.slice</refentrytitle>
|
||||
<manvolnum>5</manvolnum></citerefentry> for details.
|
||||
`[Slice]` section of the unit. See
|
||||
{manpage}`systemd.slice(5)` for details.
|
||||
'';
|
||||
};
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ in {
|
|||
options.amazonImage = {
|
||||
name = mkOption {
|
||||
type = types.str;
|
||||
description = "The name of the generated derivation";
|
||||
description = lib.mdDoc "The name of the generated derivation";
|
||||
default = "nixos-amazon-image-${config.system.nixos.label}-${pkgs.stdenv.hostPlatform.system}";
|
||||
};
|
||||
|
||||
|
@ -35,7 +35,7 @@ in {
|
|||
]
|
||||
'';
|
||||
default = [];
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
This option lists files to be copied to fixed locations in the
|
||||
generated image. Glob patterns work.
|
||||
'';
|
||||
|
@ -45,13 +45,13 @@ in {
|
|||
type = with types; either (enum [ "auto" ]) int;
|
||||
default = if config.ec2.hvm then 2048 else 8192;
|
||||
example = 8192;
|
||||
description = "The size in MB of the image";
|
||||
description = lib.mdDoc "The size in MB of the image";
|
||||
};
|
||||
|
||||
format = mkOption {
|
||||
type = types.enum [ "raw" "qcow2" "vpc" ];
|
||||
default = "vpc";
|
||||
description = "The image format to output";
|
||||
description = lib.mdDoc "The image format to output";
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -16,20 +16,20 @@ in
|
|||
options.openstackImage = {
|
||||
name = mkOption {
|
||||
type = types.str;
|
||||
description = "The name of the generated derivation";
|
||||
description = lib.mdDoc "The name of the generated derivation";
|
||||
default = "nixos-openstack-image-${config.system.nixos.label}-${pkgs.stdenv.hostPlatform.system}";
|
||||
};
|
||||
|
||||
sizeMB = mkOption {
|
||||
type = types.int;
|
||||
default = 8192;
|
||||
description = "The size in MB of the image";
|
||||
description = lib.mdDoc "The size in MB of the image";
|
||||
};
|
||||
|
||||
format = mkOption {
|
||||
type = types.enum [ "raw" "qcow2" ];
|
||||
default = "qcow2";
|
||||
description = "The image format to output";
|
||||
description = lib.mdDoc "The image format to output";
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -259,7 +259,7 @@ in
|
|||
internal = true;
|
||||
type = with types; listOf path;
|
||||
default = [ ];
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Fontconfig configuration packages.
|
||||
'';
|
||||
};
|
||||
|
|
|
@ -7,7 +7,7 @@ let
|
|||
in
|
||||
{
|
||||
options.networking.iproute2 = {
|
||||
enable = mkEnableOption "copy IP route configuration files";
|
||||
enable = mkEnableOption (lib.mdDoc "copy IP route configuration files");
|
||||
rttablesExtraConfig = mkOption {
|
||||
type = types.lines;
|
||||
default = "";
|
||||
|
|
|
@ -78,7 +78,7 @@ in {
|
|||
|
||||
options = {
|
||||
krb5 = {
|
||||
enable = mkEnableOption "building krb5.conf, configuration file for Kerberos V";
|
||||
enable = mkEnableOption (lib.mdDoc "building krb5.conf, configuration file for Kerberos V");
|
||||
|
||||
kerberos = mkOption {
|
||||
type = types.package;
|
||||
|
|
|
@ -59,7 +59,7 @@ in
|
|||
|
||||
users.ldap = {
|
||||
|
||||
enable = mkEnableOption "authentication against an LDAP server";
|
||||
enable = mkEnableOption (lib.mdDoc "authentication against an LDAP server");
|
||||
|
||||
loginPam = mkOption {
|
||||
type = types.bool;
|
||||
|
|
|
@ -77,24 +77,21 @@ in
|
|||
environment.memoryAllocator.provider = mkOption {
|
||||
type = types.enum ([ "libc" ] ++ attrNames providers);
|
||||
default = "libc";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The system-wide memory allocator.
|
||||
|
||||
Briefly, the system-wide memory allocator providers are:
|
||||
<itemizedlist>
|
||||
<listitem><para><literal>libc</literal>: the standard allocator provided by libc</para></listitem>
|
||||
${toString (mapAttrsToList
|
||||
(name: value: "<listitem><para><literal>${name}</literal>: ${value.description}</para></listitem>")
|
||||
providers)}
|
||||
</itemizedlist>
|
||||
|
||||
<warning>
|
||||
<para>
|
||||
- `libc`: the standard allocator provided by libc
|
||||
${concatStringsSep "\n" (mapAttrsToList
|
||||
(name: value: "- `${name}`: ${replaceStrings [ "\n" ] [ " " ] value.description}")
|
||||
providers)}
|
||||
|
||||
::: {.warning}
|
||||
Selecting an alternative allocator (i.e., anything other than
|
||||
<literal>libc</literal>) may result in instability, data loss,
|
||||
`libc`) may result in instability, data loss,
|
||||
and/or service failure.
|
||||
</para>
|
||||
</warning>
|
||||
:::
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
|
|
@ -8,83 +8,73 @@ in
|
|||
{
|
||||
options = {
|
||||
users.mysql = {
|
||||
enable = mkEnableOption "Authentication against a MySQL/MariaDB database";
|
||||
enable = mkEnableOption (lib.mdDoc "Authentication against a MySQL/MariaDB database");
|
||||
host = mkOption {
|
||||
type = types.str;
|
||||
example = "localhost";
|
||||
description = "The hostname of the MySQL/MariaDB server";
|
||||
description = lib.mdDoc "The hostname of the MySQL/MariaDB server";
|
||||
};
|
||||
database = mkOption {
|
||||
type = types.str;
|
||||
example = "auth";
|
||||
description = "The name of the database containing the users";
|
||||
description = lib.mdDoc "The name of the database containing the users";
|
||||
};
|
||||
user = mkOption {
|
||||
type = types.str;
|
||||
example = "nss-user";
|
||||
description = "The username to use when connecting to the database";
|
||||
description = lib.mdDoc "The username to use when connecting to the database";
|
||||
};
|
||||
passwordFile = mkOption {
|
||||
type = types.path;
|
||||
example = "/run/secrets/mysql-auth-db-passwd";
|
||||
description = "The path to the file containing the password for the user";
|
||||
description = lib.mdDoc "The path to the file containing the password for the user";
|
||||
};
|
||||
pam = mkOption {
|
||||
description = "Settings for <literal>pam_mysql</literal>";
|
||||
description = lib.mdDoc "Settings for `pam_mysql`";
|
||||
type = types.submodule {
|
||||
options = {
|
||||
table = mkOption {
|
||||
type = types.str;
|
||||
example = "users";
|
||||
description = "The name of table that maps unique login names to the passwords.";
|
||||
description = lib.mdDoc "The name of table that maps unique login names to the passwords.";
|
||||
};
|
||||
updateTable = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
example = "users_updates";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The name of the table used for password alteration. If not defined, the value
|
||||
of the <literal>table</literal> option will be used instead.
|
||||
of the `table` option will be used instead.
|
||||
'';
|
||||
};
|
||||
userColumn = mkOption {
|
||||
type = types.str;
|
||||
example = "username";
|
||||
description = "The name of the column that contains a unix login name.";
|
||||
description = lib.mdDoc "The name of the column that contains a unix login name.";
|
||||
};
|
||||
passwordColumn = mkOption {
|
||||
type = types.str;
|
||||
example = "password";
|
||||
description = "The name of the column that contains a (encrypted) password string.";
|
||||
description = lib.mdDoc "The name of the column that contains a (encrypted) password string.";
|
||||
};
|
||||
statusColumn = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
example = "status";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The name of the column or an SQL expression that indicates the status of
|
||||
the user. The status is expressed by the combination of two bitfields
|
||||
shown below:
|
||||
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>bit 0 (0x01)</literal>:
|
||||
if flagged, <literal>pam_mysql</literal> deems the account to be expired and
|
||||
returns <literal>PAM_ACCT_EXPIRED</literal>. That is, the account is supposed
|
||||
to no longer be available. Note this doesn't mean that <literal>pam_mysql</literal>
|
||||
rejects further authentication operations.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>bit 1 (0x02)</literal>:
|
||||
if flagged, <literal>pam_mysql</literal> deems the authentication token
|
||||
(password) to be expired and returns <literal>PAM_NEW_AUTHTOK_REQD</literal>.
|
||||
This ends up requiring that the user enter a new password.
|
||||
</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
- `bit 0 (0x01)`:
|
||||
if flagged, `pam_mysql` deems the account to be expired and
|
||||
returns `PAM_ACCT_EXPIRED`. That is, the account is supposed
|
||||
to no longer be available. Note this doesn't mean that `pam_mysql`
|
||||
rejects further authentication operations.
|
||||
- `bit 1 (0x02)`:
|
||||
if flagged, `pam_mysql` deems the authentication token
|
||||
(password) to be expired and returns `PAM_NEW_AUTHTOK_REQD`.
|
||||
This ends up requiring that the user enter a new password.
|
||||
'';
|
||||
};
|
||||
passwordCrypt = mkOption {
|
||||
|
@ -101,101 +91,59 @@ in
|
|||
"8" "sha512"
|
||||
"9" "sha256"
|
||||
];
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The method to encrypt the user's password:
|
||||
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>0</literal> (or <literal>"plain"</literal>):
|
||||
No encryption. Passwords are stored in plaintext. HIGHLY DISCOURAGED.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>1</literal> (or <literal>"Y"</literal>):
|
||||
Use crypt(3) function.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>2</literal> (or <literal>"mysql"</literal>):
|
||||
Use the MySQL PASSWORD() function. It is possible that the encryption function used
|
||||
by <literal>pam_mysql</literal> is different from that of the MySQL server, as
|
||||
<literal>pam_mysql</literal> uses the function defined in MySQL's C-client API
|
||||
instead of using PASSWORD() SQL function in the query.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>3</literal> (or <literal>"md5"</literal>):
|
||||
Use plain hex MD5.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>4</literal> (or <literal>"sha1"</literal>):
|
||||
Use plain hex SHA1.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>5</literal> (or <literal>"drupal7"</literal>):
|
||||
Use Drupal7 salted passwords.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>6</literal> (or <literal>"joomla15"</literal>):
|
||||
Use Joomla15 salted passwords.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>7</literal> (or <literal>"ssha"</literal>):
|
||||
Use ssha hashed passwords.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>8</literal> (or <literal>"sha512"</literal>):
|
||||
Use sha512 hashed passwords.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>9</literal> (or <literal>"sha256"</literal>):
|
||||
Use sha256 hashed passwords.
|
||||
</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
- `0` (or `"plain"`):
|
||||
No encryption. Passwords are stored in plaintext. HIGHLY DISCOURAGED.
|
||||
- `1` (or `"Y"`):
|
||||
Use crypt(3) function.
|
||||
- `2` (or `"mysql"`):
|
||||
Use the MySQL PASSWORD() function. It is possible that the encryption function used
|
||||
by `pam_mysql` is different from that of the MySQL server, as
|
||||
`pam_mysql` uses the function defined in MySQL's C-client API
|
||||
instead of using PASSWORD() SQL function in the query.
|
||||
- `3` (or `"md5"`):
|
||||
Use plain hex MD5.
|
||||
- `4` (or `"sha1"`):
|
||||
Use plain hex SHA1.
|
||||
- `5` (or `"drupal7"`):
|
||||
Use Drupal7 salted passwords.
|
||||
- `6` (or `"joomla15"`):
|
||||
Use Joomla15 salted passwords.
|
||||
- `7` (or `"ssha"`):
|
||||
Use ssha hashed passwords.
|
||||
- `8` (or `"sha512"`):
|
||||
Use sha512 hashed passwords.
|
||||
- `9` (or `"sha256"`):
|
||||
Use sha256 hashed passwords.
|
||||
'';
|
||||
};
|
||||
cryptDefault = mkOption {
|
||||
type = types.nullOr (types.enum [ "md5" "sha256" "sha512" "blowfish" ]);
|
||||
default = null;
|
||||
example = "blowfish";
|
||||
description = "The default encryption method to use for <literal>passwordCrypt = 1</literal>.";
|
||||
description = lib.mdDoc "The default encryption method to use for `passwordCrypt = 1`.";
|
||||
};
|
||||
where = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
example = "host.name='web' AND user.active=1";
|
||||
description = "Additional criteria for the query.";
|
||||
description = lib.mdDoc "Additional criteria for the query.";
|
||||
};
|
||||
verbose = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
If enabled, produces logs with detailed messages that describes what
|
||||
<literal>pam_mysql</literal> is doing. May be useful for debugging.
|
||||
`pam_mysql` is doing. May be useful for debugging.
|
||||
'';
|
||||
};
|
||||
disconnectEveryOperation = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
description = ''
|
||||
By default, <literal>pam_mysql</literal> keeps the connection to the MySQL
|
||||
description = lib.mdDoc ''
|
||||
By default, `pam_mysql` keeps the connection to the MySQL
|
||||
database until the session is closed. If this option is set to true it
|
||||
disconnects every time the PAM operation has finished. This option may
|
||||
be useful in case the session lasts quite long.
|
||||
|
@ -205,17 +153,17 @@ in
|
|||
enable = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
description = "Enables logging of authentication attempts in the MySQL database.";
|
||||
description = lib.mdDoc "Enables logging of authentication attempts in the MySQL database.";
|
||||
};
|
||||
table = mkOption {
|
||||
type = types.str;
|
||||
example = "logs";
|
||||
description = "The name of the table to which logs are written.";
|
||||
description = lib.mdDoc "The name of the table to which logs are written.";
|
||||
};
|
||||
msgColumn = mkOption {
|
||||
type = types.str;
|
||||
example = "msg";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The name of the column in the log table to which the description
|
||||
of the performed operation is stored.
|
||||
'';
|
||||
|
@ -223,7 +171,7 @@ in
|
|||
userColumn = mkOption {
|
||||
type = types.str;
|
||||
example = "user";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The name of the column in the log table to which the name of the
|
||||
user being authenticated is stored.
|
||||
'';
|
||||
|
@ -231,16 +179,16 @@ in
|
|||
pidColumn = mkOption {
|
||||
type = types.str;
|
||||
example = "pid";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The name of the column in the log table to which the pid of the
|
||||
process utilising the <literal>pam_mysql's</literal> authentication
|
||||
process utilising the `pam_mysql's` authentication
|
||||
service is stored.
|
||||
'';
|
||||
};
|
||||
hostColumn = mkOption {
|
||||
type = types.str;
|
||||
example = "host";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The name of the column in the log table to which the name of the user
|
||||
being authenticated is stored.
|
||||
'';
|
||||
|
@ -248,17 +196,16 @@ in
|
|||
rHostColumn = mkOption {
|
||||
type = types.str;
|
||||
example = "rhost";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The name of the column in the log table to which the name of the remote
|
||||
host that initiates the session is stored. The value is supposed to be
|
||||
set by the PAM-aware application with <literal>pam_set_item(PAM_RHOST)
|
||||
</literal>.
|
||||
set by the PAM-aware application with `pam_set_item(PAM_RHOST)`.
|
||||
'';
|
||||
};
|
||||
timeColumn = mkOption {
|
||||
type = types.str;
|
||||
example = "timestamp";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The name of the column in the log table to which the timestamp of the
|
||||
log entry is stored.
|
||||
'';
|
||||
|
@ -268,11 +215,11 @@ in
|
|||
};
|
||||
};
|
||||
nss = mkOption {
|
||||
description = ''
|
||||
Settings for <literal>libnss-mysql</literal>.
|
||||
description = lib.mdDoc ''
|
||||
Settings for `libnss-mysql`.
|
||||
|
||||
All examples are from the <link xlink:href="https://github.com/saknopper/libnss-mysql/tree/master/sample/minimal">minimal example</link>
|
||||
of <literal>libnss-mysql</literal>, but they are modified with NixOS paths for bash.
|
||||
All examples are from the [minimal example](https://github.com/saknopper/libnss-mysql/tree/master/sample/minimal)
|
||||
of `libnss-mysql`, but they are modified with NixOS paths for bash.
|
||||
'';
|
||||
type = types.submodule {
|
||||
options = {
|
||||
|
@ -285,9 +232,8 @@ in
|
|||
WHERE username='%1$s' \
|
||||
LIMIT 1
|
||||
'';
|
||||
description = ''
|
||||
SQL query for the <link
|
||||
xlink:href="https://man7.org/linux/man-pages/man3/getpwnam.3.html">getpwnam</link>
|
||||
description = lib.mdDoc ''
|
||||
SQL query for the [getpwnam](https://man7.org/linux/man-pages/man3/getpwnam.3.html)
|
||||
syscall.
|
||||
'';
|
||||
};
|
||||
|
@ -300,9 +246,8 @@ in
|
|||
WHERE uid='%1$u' \
|
||||
LIMIT 1
|
||||
'';
|
||||
description = ''
|
||||
SQL query for the <link
|
||||
xlink:href="https://man7.org/linux/man-pages/man3/getpwuid.3.html">getpwuid</link>
|
||||
description = lib.mdDoc ''
|
||||
SQL query for the [getpwuid](https://man7.org/linux/man-pages/man3/getpwuid.3.html)
|
||||
syscall.
|
||||
'';
|
||||
};
|
||||
|
@ -315,9 +260,8 @@ in
|
|||
WHERE username='%1$s' \
|
||||
LIMIT 1
|
||||
'';
|
||||
description = ''
|
||||
SQL query for the <link
|
||||
xlink:href="https://man7.org/linux/man-pages/man3/getspnam.3.html">getspnam</link>
|
||||
description = lib.mdDoc ''
|
||||
SQL query for the [getspnam](https://man7.org/linux/man-pages/man3/getspnam.3.html)
|
||||
syscall.
|
||||
'';
|
||||
};
|
||||
|
@ -327,9 +271,8 @@ in
|
|||
example = literalExpression ''
|
||||
SELECT username,'x',uid,'5000','MySQL User', CONCAT('/home/',username),'/run/sw/current-system/bin/bash' FROM users
|
||||
'';
|
||||
description = ''
|
||||
SQL query for the <link
|
||||
xlink:href="https://man7.org/linux/man-pages/man3/getpwent.3.html">getpwent</link>
|
||||
description = lib.mdDoc ''
|
||||
SQL query for the [getpwent](https://man7.org/linux/man-pages/man3/getpwent.3.html)
|
||||
syscall.
|
||||
'';
|
||||
};
|
||||
|
@ -339,9 +282,8 @@ in
|
|||
example = literalExpression ''
|
||||
SELECT username,password,'1','0','99999','0','0','-1','0' FROM users
|
||||
'';
|
||||
description = ''
|
||||
SQL query for the <link
|
||||
xlink:href="https://man7.org/linux/man-pages/man3/getspent.3.html">getspent</link>
|
||||
description = lib.mdDoc ''
|
||||
SQL query for the [getspent](https://man7.org/linux/man-pages/man3/getspent.3.html)
|
||||
syscall.
|
||||
'';
|
||||
};
|
||||
|
@ -351,9 +293,8 @@ in
|
|||
example = literalExpression ''
|
||||
SELECT name,password,gid FROM groups WHERE name='%1$s' LIMIT 1
|
||||
'';
|
||||
description = ''
|
||||
SQL query for the <link
|
||||
xlink:href="https://man7.org/linux/man-pages/man3/getgrnam.3.html">getgrnam</link>
|
||||
description = lib.mdDoc ''
|
||||
SQL query for the [getgrnam](https://man7.org/linux/man-pages/man3/getgrnam.3.html)
|
||||
syscall.
|
||||
'';
|
||||
};
|
||||
|
@ -363,9 +304,8 @@ in
|
|||
example = literalExpression ''
|
||||
SELECT name,password,gid FROM groups WHERE gid='%1$u' LIMIT 1
|
||||
'';
|
||||
description = ''
|
||||
SQL query for the <link
|
||||
xlink:href="https://man7.org/linux/man-pages/man3/getgrgid.3.html">getgrgid</link>
|
||||
description = lib.mdDoc ''
|
||||
SQL query for the [getgrgid](https://man7.org/linux/man-pages/man3/getgrgid.3.html)
|
||||
syscall.
|
||||
'';
|
||||
};
|
||||
|
@ -375,9 +315,8 @@ in
|
|||
example = literalExpression ''
|
||||
SELECT name,password,gid FROM groups
|
||||
'';
|
||||
description = ''
|
||||
SQL query for the <link
|
||||
xlink:href="https://man7.org/linux/man-pages/man3/getgrent.3.html">getgrent</link>
|
||||
description = lib.mdDoc ''
|
||||
SQL query for the [getgrent](https://man7.org/linux/man-pages/man3/getgrent.3.html)
|
||||
syscall.
|
||||
'';
|
||||
};
|
||||
|
@ -387,9 +326,8 @@ in
|
|||
example = literalExpression ''
|
||||
SELECT username FROM grouplist WHERE gid='%1$u'
|
||||
'';
|
||||
description = ''
|
||||
SQL query for the <link
|
||||
xlink:href="https://man7.org/linux/man-pages/man3/memsbygid.3.html">memsbygid</link>
|
||||
description = lib.mdDoc ''
|
||||
SQL query for the [memsbygid](https://man7.org/linux/man-pages/man3/memsbygid.3.html)
|
||||
syscall.
|
||||
'';
|
||||
};
|
||||
|
@ -399,9 +337,8 @@ in
|
|||
example = literalExpression ''
|
||||
SELECT gid FROM grouplist WHERE username='%1$s'
|
||||
'';
|
||||
description = ''
|
||||
SQL query for the <link
|
||||
xlink:href="https://man7.org/linux/man-pages/man3/gidsbymem.3.html">gidsbymem</link>
|
||||
description = lib.mdDoc ''
|
||||
SQL query for the [gidsbymem](https://man7.org/linux/man-pages/man3/gidsbymem.3.html)
|
||||
syscall.
|
||||
'';
|
||||
};
|
||||
|
|
|
@ -141,7 +141,7 @@ in
|
|||
type = types.attrs;
|
||||
internal = true;
|
||||
default = {};
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Environment variables used for the network proxy.
|
||||
'';
|
||||
};
|
||||
|
|
|
@ -190,17 +190,17 @@ in {
|
|||
|
||||
zeroconf = {
|
||||
discovery.enable =
|
||||
mkEnableOption "discovery of pulseaudio sinks in the local network";
|
||||
mkEnableOption (lib.mdDoc "discovery of pulseaudio sinks in the local network");
|
||||
publish.enable =
|
||||
mkEnableOption "publishing the pulseaudio sink in the local network";
|
||||
mkEnableOption (lib.mdDoc "publishing the pulseaudio sink in the local network");
|
||||
};
|
||||
|
||||
# TODO: enable by default?
|
||||
tcp = {
|
||||
enable = mkEnableOption "tcp streaming support";
|
||||
enable = mkEnableOption (lib.mdDoc "tcp streaming support");
|
||||
|
||||
anonymousClients = {
|
||||
allowAll = mkEnableOption "all anonymous clients to stream to the server";
|
||||
allowAll = mkEnableOption (lib.mdDoc "all anonymous clients to stream to the server");
|
||||
allowedIpRanges = mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = [];
|
||||
|
|
|
@ -27,7 +27,7 @@ in
|
|||
options = {
|
||||
qt5 = {
|
||||
|
||||
enable = mkEnableOption "Qt5 theming configuration";
|
||||
enable = mkEnableOption (lib.mdDoc "Qt5 theming configuration");
|
||||
|
||||
platformTheme = mkOption {
|
||||
type = types.enum [
|
||||
|
|
|
@ -140,9 +140,9 @@ in
|
|||
example = literalExpression ''"''${pkgs.dash}/bin/dash"'';
|
||||
type = types.path;
|
||||
visible = false;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The shell executable that is linked system-wide to
|
||||
<literal>/bin/sh</literal>. Please note that NixOS assumes all
|
||||
`/bin/sh`. Please note that NixOS assumes all
|
||||
over the place that shell to be Bash, so override the default
|
||||
setting only if you know exactly what you're doing.
|
||||
'';
|
||||
|
|
|
@ -73,8 +73,8 @@ let
|
|||
label = mkOption {
|
||||
example = "swap";
|
||||
type = types.str;
|
||||
description = ''
|
||||
Label of the device. Can be used instead of <varname>device</varname>.
|
||||
description = lib.mdDoc ''
|
||||
Label of the device. Can be used instead of {var}`device`.
|
||||
'';
|
||||
};
|
||||
|
||||
|
|
|
@ -132,7 +132,7 @@ in
|
|||
|
||||
path = mkOption {
|
||||
internal = true;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The packages you want in the boot environment.
|
||||
'';
|
||||
};
|
||||
|
|
|
@ -33,7 +33,7 @@ in
|
|||
|
||||
options.xdg.portal = {
|
||||
enable =
|
||||
mkEnableOption ''<link xlink:href="https://github.com/flatpak/xdg-desktop-portal">xdg desktop integration</link>'' // {
|
||||
mkEnableOption (lib.mdDoc ''[xdg desktop integration](https://github.com/flatpak/xdg-desktop-portal)'') // {
|
||||
default = false;
|
||||
};
|
||||
|
||||
|
@ -54,11 +54,11 @@ in
|
|||
type = types.bool;
|
||||
visible = false;
|
||||
default = false;
|
||||
description = ''
|
||||
Sets environment variable <literal>GTK_USE_PORTAL</literal> to <literal>1</literal>.
|
||||
description = lib.mdDoc ''
|
||||
Sets environment variable `GTK_USE_PORTAL` to `1`.
|
||||
This will force GTK-based programs ran outside Flatpak to respect and use XDG Desktop Portals
|
||||
for features like file chooser but it is an unsupported hack that can easily break things.
|
||||
Defaults to <literal>false</literal> to respect its opt-in nature.
|
||||
Defaults to `false` to respect its opt-in nature.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
|
|
@ -12,13 +12,13 @@ in
|
|||
};
|
||||
|
||||
options.xdg.portal.lxqt = {
|
||||
enable = mkEnableOption ''
|
||||
enable = mkEnableOption (lib.mdDoc ''
|
||||
the desktop portal for the LXQt desktop environment.
|
||||
|
||||
This will add the <literal>lxqt.xdg-desktop-portal-lxqt</literal>
|
||||
This will add the `lxqt.xdg-desktop-portal-lxqt`
|
||||
package (with the extra Qt styles) into the
|
||||
<option>xdg.portal.extraPortals</option> option
|
||||
'';
|
||||
{option}`xdg.portal.extraPortals` option
|
||||
'');
|
||||
|
||||
styles = mkOption {
|
||||
type = types.listOf types.package;
|
||||
|
|
|
@ -14,13 +14,13 @@ in
|
|||
};
|
||||
|
||||
options.xdg.portal.wlr = {
|
||||
enable = mkEnableOption ''
|
||||
enable = mkEnableOption (lib.mdDoc ''
|
||||
desktop portal for wlroots-based desktops
|
||||
|
||||
This will add the <literal>xdg-desktop-portal-wlr</literal> package into
|
||||
the <option>xdg.portal.extraPortals</option> option, and provide the
|
||||
This will add the `xdg-desktop-portal-wlr` package into
|
||||
the {option}`xdg.portal.extraPortals` option, and provide the
|
||||
configuration file
|
||||
'';
|
||||
'');
|
||||
|
||||
settings = mkOption {
|
||||
description = lib.mdDoc ''
|
||||
|
|
|
@ -7,10 +7,10 @@ in
|
|||
{
|
||||
options = {
|
||||
hardware.brillo = {
|
||||
enable = mkEnableOption ''
|
||||
enable = mkEnableOption (lib.mdDoc ''
|
||||
Enable brillo in userspace.
|
||||
This will allow brightness control from users in the video group.
|
||||
'';
|
||||
'');
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@ in
|
|||
];
|
||||
|
||||
options.hardware.ckb-next = {
|
||||
enable = mkEnableOption "the Corsair keyboard/mouse driver";
|
||||
enable = mkEnableOption (lib.mdDoc "the Corsair keyboard/mouse driver");
|
||||
|
||||
gid = mkOption {
|
||||
type = types.nullOr types.int;
|
||||
|
|
|
@ -7,15 +7,15 @@ let
|
|||
in
|
||||
{
|
||||
options.programs.corectrl = {
|
||||
enable = mkEnableOption ''
|
||||
enable = mkEnableOption (lib.mdDoc ''
|
||||
A tool to overclock amd graphics cards and processors.
|
||||
Add your user to the corectrl group to run corectrl without needing to enter your password
|
||||
'';
|
||||
'');
|
||||
|
||||
gpuOverclock = {
|
||||
enable = mkEnableOption ''
|
||||
enable = mkEnableOption (lib.mdDoc ''
|
||||
true
|
||||
'';
|
||||
'');
|
||||
ppfeaturemask = mkOption {
|
||||
type = types.str;
|
||||
default = "0xfffd7fff";
|
||||
|
|
|
@ -6,7 +6,7 @@ let
|
|||
in
|
||||
with lib; {
|
||||
options.hardware.cpu.amd.sev = {
|
||||
enable = mkEnableOption "access to the AMD SEV device";
|
||||
enable = mkEnableOption (lib.mdDoc "access to the AMD SEV device");
|
||||
user = mkOption {
|
||||
description = lib.mdDoc "Owner to assign to the SEV device.";
|
||||
type = types.str;
|
||||
|
|
|
@ -20,7 +20,7 @@ in
|
|||
};
|
||||
|
||||
options.hardware.cpu.intel.sgx.provision = {
|
||||
enable = mkEnableOption "access to the Intel SGX provisioning device";
|
||||
enable = mkEnableOption (lib.mdDoc "access to the Intel SGX provisioning device");
|
||||
user = mkOption {
|
||||
description = lib.mdDoc "Owner to assign to the SGX provisioning device.";
|
||||
type = types.str;
|
||||
|
|
|
@ -171,7 +171,7 @@ in
|
|||
default = null;
|
||||
type = types.nullOr types.path;
|
||||
internal = true;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
A path containing the result of applying `overlays` to `kernelPackage`.
|
||||
'';
|
||||
};
|
||||
|
|
|
@ -3,7 +3,7 @@ let
|
|||
cfg = config.hardware.flirc;
|
||||
in
|
||||
{
|
||||
options.hardware.flirc.enable = lib.mkEnableOption "software to configure a Flirc USB device";
|
||||
options.hardware.flirc.enable = lib.mkEnableOption (lib.mdDoc "software to configure a Flirc USB device");
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
environment.systemPackages = [ pkgs.flirc ];
|
||||
|
|
|
@ -7,7 +7,7 @@ let
|
|||
in
|
||||
{
|
||||
options.hardware.gkraken = {
|
||||
enable = mkEnableOption "gkraken's udev rules for NZXT AIO liquid coolers";
|
||||
enable = mkEnableOption (lib.mdDoc "gkraken's udev rules for NZXT AIO liquid coolers");
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
|
|
@ -28,7 +28,7 @@ let
|
|||
cfg = config.hardware.gpgSmartcards;
|
||||
in {
|
||||
options.hardware.gpgSmartcards = {
|
||||
enable = mkEnableOption "udev rules for gnupg smart cards";
|
||||
enable = mkEnableOption (lib.mdDoc "udev rules for gnupg smart cards");
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
|
|
@ -8,11 +8,11 @@ in
|
|||
|
||||
{
|
||||
options.hardware.i2c = {
|
||||
enable = mkEnableOption ''
|
||||
enable = mkEnableOption (lib.mdDoc ''
|
||||
i2c devices support. By default access is granted to users in the "i2c"
|
||||
group (will be created if non-existent) and any user with a seat, meaning
|
||||
logged on the computer locally.
|
||||
'';
|
||||
'');
|
||||
|
||||
group = mkOption {
|
||||
type = types.str;
|
||||
|
|
|
@ -6,7 +6,7 @@ let
|
|||
in
|
||||
{
|
||||
options.hardware.keyboard.teck = {
|
||||
enable = mkEnableOption "non-root access to the firmware of TECK keyboards";
|
||||
enable = mkEnableOption (lib.mdDoc "non-root access to the firmware of TECK keyboards");
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
|
|
@ -6,12 +6,12 @@ let
|
|||
in
|
||||
{
|
||||
options.hardware.keyboard.uhk = {
|
||||
enable = mkEnableOption ''
|
||||
enable = mkEnableOption (lib.mdDoc ''
|
||||
non-root access to the firmware of UHK keyboards.
|
||||
You need it when you want to flash a new firmware on the keyboard.
|
||||
Access to the keyboard is granted to users in the "input" group.
|
||||
You may want to install the uhk-agent package.
|
||||
'';
|
||||
'');
|
||||
|
||||
};
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@ in {
|
|||
];
|
||||
|
||||
options.hardware.ksm = {
|
||||
enable = mkEnableOption "Kernel Same-Page Merging";
|
||||
enable = mkEnableOption (lib.mdDoc "Kernel Same-Page Merging");
|
||||
sleep = mkOption {
|
||||
type = types.nullOr types.int;
|
||||
default = null;
|
||||
|
|
|
@ -6,7 +6,7 @@ let
|
|||
cfg = config.hardware.ledger;
|
||||
|
||||
in {
|
||||
options.hardware.ledger.enable = mkEnableOption "udev rules for Ledger devices";
|
||||
options.hardware.ledger.enable = mkEnableOption (lib.mdDoc "udev rules for Ledger devices");
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
services.udev.packages = [ pkgs.ledger-udev-rules ];
|
||||
|
|
|
@ -19,7 +19,7 @@ in
|
|||
options.hardware.logitech = {
|
||||
|
||||
lcd = {
|
||||
enable = mkEnableOption "Logitech LCD Devices";
|
||||
enable = mkEnableOption (lib.mdDoc "Logitech LCD Devices");
|
||||
|
||||
startWhenNeeded = mkOption {
|
||||
type = types.bool;
|
||||
|
@ -41,7 +41,7 @@ in
|
|||
};
|
||||
|
||||
wireless = {
|
||||
enable = mkEnableOption "Logitech Wireless Devices";
|
||||
enable = mkEnableOption (lib.mdDoc "Logitech Wireless Devices");
|
||||
|
||||
enableGraphical = mkOption {
|
||||
type = types.bool;
|
||||
|
|
|
@ -71,7 +71,7 @@ in
|
|||
package = mkOption {
|
||||
type = types.package;
|
||||
internal = true;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The package that provides the OpenGL implementation.
|
||||
'';
|
||||
};
|
||||
|
@ -79,9 +79,9 @@ in
|
|||
package32 = mkOption {
|
||||
type = types.package;
|
||||
internal = true;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The package that provides the 32-bit OpenGL implementation on
|
||||
64-bit systems. Used when <option>driSupport32Bit</option> is
|
||||
64-bit systems. Used when {option}`driSupport32Bit` is
|
||||
set.
|
||||
'';
|
||||
};
|
||||
|
@ -111,11 +111,11 @@ in
|
|||
type = types.bool;
|
||||
internal = true;
|
||||
default = false;
|
||||
description = ''
|
||||
Whether the <literal>LD_LIBRARY_PATH</literal> environment variable
|
||||
description = lib.mdDoc ''
|
||||
Whether the `LD_LIBRARY_PATH` environment variable
|
||||
should be set to the locations of driver libraries. Drivers which
|
||||
rely on overriding libraries should set this to true. Drivers which
|
||||
support <literal>libglvnd</literal> and other dispatch libraries
|
||||
support `libglvnd` and other dispatch libraries
|
||||
instead of overriding libraries should not set this.
|
||||
'';
|
||||
};
|
||||
|
|
|
@ -49,9 +49,9 @@ in
|
|||
{
|
||||
options = {
|
||||
hardware.openrazer = {
|
||||
enable = mkEnableOption ''
|
||||
enable = mkEnableOption (lib.mdDoc ''
|
||||
OpenRazer drivers and userspace daemon.
|
||||
'';
|
||||
'');
|
||||
|
||||
verboseLogging = mkOption {
|
||||
type = types.bool;
|
||||
|
|
|
@ -48,7 +48,7 @@ in {
|
|||
|
||||
options = {
|
||||
hardware.raid.HPSmartArray = {
|
||||
enable = mkEnableOption "HP Smart Array kernel modules and CLI utility";
|
||||
enable = mkEnableOption (lib.mdDoc "HP Smart Array kernel modules and CLI utility");
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@ let
|
|||
in
|
||||
{
|
||||
options.hardware.saleae-logic = {
|
||||
enable = lib.mkEnableOption "udev rules for Saleae Logic devices";
|
||||
enable = lib.mkEnableOption (lib.mdDoc "udev rules for Saleae Logic devices");
|
||||
|
||||
package = lib.mkOption {
|
||||
type = lib.types.package;
|
||||
|
|
|
@ -36,7 +36,7 @@ in
|
|||
meta.maintainers = with lib.maintainers; [ peterhoeg ];
|
||||
|
||||
options.hardware.sata.timeout = {
|
||||
enable = mkEnableOption "SATA drive timeouts";
|
||||
enable = mkEnableOption (lib.mdDoc "SATA drive timeouts");
|
||||
|
||||
deciSeconds = mkOption {
|
||||
example = 70;
|
||||
|
|
|
@ -57,7 +57,7 @@ let
|
|||
in {
|
||||
options = {
|
||||
hardware.system76 = {
|
||||
enableAll = mkEnableOption "all recommended configuration for system76 systems";
|
||||
enableAll = mkEnableOption (lib.mdDoc "all recommended configuration for system76 systems");
|
||||
|
||||
firmware-daemon.enable = mkOption {
|
||||
default = cfg.enableAll;
|
||||
|
|
|
@ -8,23 +8,23 @@ let
|
|||
in
|
||||
{
|
||||
options.hardware.tuxedo-keyboard = {
|
||||
enable = mkEnableOption ''
|
||||
enable = mkEnableOption (lib.mdDoc ''
|
||||
Enables the tuxedo-keyboard driver.
|
||||
|
||||
To configure the driver, pass the options to the <option>boot.kernelParams</option> configuration.
|
||||
To configure the driver, pass the options to the {option}`boot.kernelParams` configuration.
|
||||
There are several parameters you can change. It's best to check at the source code description which options are supported.
|
||||
You can find all the supported parameters at: <link xlink:href="https://github.com/tuxedocomputers/tuxedo-keyboard#kernelparam"/>
|
||||
You can find all the supported parameters at: <https://github.com/tuxedocomputers/tuxedo-keyboard#kernelparam>
|
||||
|
||||
In order to use the <literal>custom</literal> lighting with the maximumg brightness and a color of <literal>0xff0a0a</literal> one would put pass <option>boot.kernelParams</option> like this:
|
||||
In order to use the `custom` lighting with the maximumg brightness and a color of `0xff0a0a` one would put pass {option}`boot.kernelParams` like this:
|
||||
|
||||
<programlisting>
|
||||
```
|
||||
boot.kernelParams = [
|
||||
"tuxedo_keyboard.mode=0"
|
||||
"tuxedo_keyboard.brightness=255"
|
||||
"tuxedo_keyboard.color_left=0xff0a0a"
|
||||
];
|
||||
</programlisting>
|
||||
'';
|
||||
```
|
||||
'');
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable
|
||||
|
|
|
@ -10,7 +10,7 @@ let
|
|||
};
|
||||
in {
|
||||
options.hardware.ubertooth = {
|
||||
enable = mkEnableOption "Enable the Ubertooth software and its udev rules.";
|
||||
enable = mkEnableOption (lib.mdDoc "Enable the Ubertooth software and its udev rules.");
|
||||
|
||||
group = mkOption {
|
||||
type = types.str;
|
||||
|
|
|
@ -4,7 +4,7 @@ let
|
|||
cfg = config.hardware.uinput;
|
||||
in {
|
||||
options.hardware.uinput = {
|
||||
enable = lib.mkEnableOption "uinput support";
|
||||
enable = lib.mkEnableOption (lib.mdDoc "uinput support");
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
|
|
|
@ -12,7 +12,7 @@ in
|
|||
|
||||
{
|
||||
|
||||
options.hardware.mwProCapture.enable = mkEnableOption "Magewell Pro Capture family kernel module";
|
||||
options.hardware.mwProCapture.enable = mkEnableOption (lib.mdDoc "Magewell Pro Capture family kernel module");
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
with lib;
|
||||
|
||||
{
|
||||
options.hardware.video.hidpi.enable = mkEnableOption "Font/DPI configuration optimized for HiDPI displays";
|
||||
options.hardware.video.hidpi.enable = mkEnableOption (lib.mdDoc "Font/DPI configuration optimized for HiDPI displays");
|
||||
|
||||
config = mkIf config.hardware.video.hidpi.enable {
|
||||
console.font = lib.mkDefault "${pkgs.terminus_font}/share/consolefonts/ter-v32n.psf.gz";
|
||||
|
|
|
@ -6,7 +6,7 @@ let
|
|||
cfg = config.services.switcherooControl;
|
||||
in {
|
||||
options.services.switcherooControl = {
|
||||
enable = mkEnableOption "switcheroo-control, a D-Bus service to check the availability of dual-GPU";
|
||||
enable = mkEnableOption (lib.mdDoc "switcheroo-control, a D-Bus service to check the availability of dual-GPU");
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
|
|
@ -12,7 +12,7 @@ in
|
|||
|
||||
{
|
||||
|
||||
options.hardware.facetimehd.enable = mkEnableOption "facetimehd kernel module";
|
||||
options.hardware.facetimehd.enable = mkEnableOption (lib.mdDoc "facetimehd kernel module");
|
||||
|
||||
options.hardware.facetimehd.withCalibration = mkOption {
|
||||
default = false;
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
with lib;
|
||||
{
|
||||
options.hardware.wooting.enable =
|
||||
mkEnableOption "Enable support for Wooting keyboards";
|
||||
mkEnableOption (lib.mdDoc "Enable support for Wooting keyboards");
|
||||
|
||||
config = mkIf config.hardware.wooting.enable {
|
||||
environment.systemPackages = [ pkgs.wootility ];
|
||||
|
|
|
@ -6,7 +6,7 @@ let
|
|||
in
|
||||
{
|
||||
options.hardware.xone = {
|
||||
enable = mkEnableOption "the xone driver for Xbox One and Xbobx Series X|S accessories";
|
||||
enable = mkEnableOption (lib.mdDoc "the xone driver for Xbox One and Xbobx Series X|S accessories");
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
|
|
@ -6,7 +6,7 @@ let
|
|||
in
|
||||
{
|
||||
options.hardware.xpadneo = {
|
||||
enable = mkEnableOption "the xpadneo driver for Xbox One wireless controllers";
|
||||
enable = mkEnableOption (lib.mdDoc "the xpadneo driver for Xbox One wireless controllers");
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
|
|
@ -32,22 +32,20 @@ in
|
|||
type = types.nullOr (types.enum [ "ibus" "fcitx" "fcitx5" "nabi" "uim" "hime" "kime" ]);
|
||||
default = null;
|
||||
example = "fcitx";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Select the enabled input method. Input methods is a software to input symbols that are not available on standard input devices.
|
||||
|
||||
Input methods are specially used to input Chinese, Japanese and Korean characters.
|
||||
|
||||
Currently the following input methods are available in NixOS:
|
||||
|
||||
<itemizedlist>
|
||||
<listitem><para>ibus: The intelligent input bus, extra input engines can be added using <literal>i18n.inputMethod.ibus.engines</literal>.</para></listitem>
|
||||
<listitem><para>fcitx: A customizable lightweight input method, extra input engines can be added using <literal>i18n.inputMethod.fcitx.engines</literal>.</para></listitem>
|
||||
<listitem><para>fcitx5: The next generation of fcitx, addons (including engines, dictionaries, skins) can be added using <literal>i18n.inputMethod.fcitx5.addons</literal>.</para></listitem>
|
||||
<listitem><para>nabi: A Korean input method based on XIM. Nabi doesn't support Qt 5.</para></listitem>
|
||||
<listitem><para>uim: The universal input method, is a library with a XIM bridge. uim mainly support Chinese, Japanese and Korean.</para></listitem>
|
||||
<listitem><para>hime: An extremely easy-to-use input method framework.</para></listitem>
|
||||
<listitem><para>kime: Koream IME.</para></listitem>
|
||||
</itemizedlist>
|
||||
- ibus: The intelligent input bus, extra input engines can be added using `i18n.inputMethod.ibus.engines`.
|
||||
- fcitx: A customizable lightweight input method, extra input engines can be added using `i18n.inputMethod.fcitx.engines`.
|
||||
- fcitx5: The next generation of fcitx, addons (including engines, dictionaries, skins) can be added using `i18n.inputMethod.fcitx5.addons`.
|
||||
- nabi: A Korean input method based on XIM. Nabi doesn't support Qt 5.
|
||||
- uim: The universal input method, is a library with a XIM bridge. uim mainly support Chinese, Japanese and Korean.
|
||||
- hime: An extremely easy-to-use input method framework.
|
||||
- kime: Koream IME.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -55,7 +53,7 @@ in
|
|||
internal = true;
|
||||
type = types.nullOr types.path;
|
||||
default = null;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The input method method package.
|
||||
'';
|
||||
};
|
||||
|
|
|
@ -20,7 +20,7 @@ in {
|
|||
'';
|
||||
};
|
||||
|
||||
enableRimeData = mkEnableOption "default rime-data with fcitx5-rime";
|
||||
enableRimeData = mkEnableOption (lib.mdDoc "default rime-data with fcitx5-rime");
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -58,7 +58,7 @@ in
|
|||
firmwarePartitionOffset = mkOption {
|
||||
type = types.int;
|
||||
default = 8;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Gap in front of the /boot/firmware partition, in mebibytes (1024×1024
|
||||
bytes).
|
||||
Can be increased to make more space for boards requiring to dd u-boot
|
||||
|
|
|
@ -11,7 +11,7 @@ with lib;
|
|||
internal = true;
|
||||
default = [];
|
||||
example = [ { assertion = false; message = "you can't enable this for that reason"; } ];
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
This option allows modules to express conditions that must
|
||||
hold for the evaluation of the system configuration to
|
||||
succeed, along with associated error messages for the user.
|
||||
|
@ -23,7 +23,7 @@ with lib;
|
|||
default = [];
|
||||
type = types.listOf types.str;
|
||||
example = [ "The `foo' service is deprecated and will go away soon!" ];
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
This option allows modules to show warnings to users during
|
||||
the evaluation of the system configuration.
|
||||
'';
|
||||
|
|
|
@ -226,15 +226,14 @@ in
|
|||
nixos.enable = mkOption {
|
||||
type = types.bool;
|
||||
default = true;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Whether to install NixOS's own documentation.
|
||||
<itemizedlist>
|
||||
<listitem><para>This includes man pages like
|
||||
<citerefentry><refentrytitle>configuration.nix</refentrytitle><manvolnum>5</manvolnum></citerefentry> if <option>documentation.man.enable</option> is
|
||||
set.</para></listitem>
|
||||
<listitem><para>This includes the HTML manual and the <command>nixos-help</command> command if
|
||||
<option>documentation.doc.enable</option> is set.</para></listitem>
|
||||
</itemizedlist>
|
||||
|
||||
- This includes man pages like
|
||||
{manpage}`configuration.nix(5)` if {option}`documentation.man.enable` is
|
||||
set.
|
||||
- This includes the HTML manual and the {command}`nixos-help` command if
|
||||
{option}`documentation.doc.enable` is set.
|
||||
'';
|
||||
};
|
||||
|
||||
|
|
|
@ -30,7 +30,7 @@ let
|
|||
specialArgs.someArg.myModule = { lib, ... }: {
|
||||
options.foobar = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "The foobar option was added via specialArgs";
|
||||
description = lib.mdDoc "The foobar option was added via specialArgs";
|
||||
default = "qux";
|
||||
};
|
||||
};
|
||||
|
|
|
@ -19,7 +19,7 @@ in
|
|||
|
||||
ids.uids = lib.mkOption {
|
||||
internal = true;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The user IDs used in NixOS.
|
||||
'';
|
||||
type = types.attrsOf types.int;
|
||||
|
@ -27,7 +27,7 @@ in
|
|||
|
||||
ids.gids = lib.mkOption {
|
||||
internal = true;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
The group IDs used in NixOS.
|
||||
'';
|
||||
type = types.attrsOf types.int;
|
||||
|
|
|
@ -12,7 +12,7 @@ in
|
|||
|
||||
nixos.label = mkOption {
|
||||
type = types.strMatching "[a-zA-Z0-9:_\\.-]*";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
NixOS version name to be used in the names of generated
|
||||
outputs and boot labels.
|
||||
|
||||
|
@ -20,25 +20,26 @@ in
|
|||
this is the option for you.
|
||||
|
||||
It can only contain letters, numbers and the following symbols:
|
||||
<literal>:</literal>, <literal>_</literal>, <literal>.</literal> and <literal>-</literal>.
|
||||
`:`, `_`, `.` and `-`.
|
||||
|
||||
The default is <option>system.nixos.tags</option> separated by
|
||||
"-" + "-" + <envar>NIXOS_LABEL_VERSION</envar> environment
|
||||
The default is {option}`system.nixos.tags` separated by
|
||||
"-" + "-" + {env}`NIXOS_LABEL_VERSION` environment
|
||||
variable (defaults to the value of
|
||||
<option>system.nixos.version</option>).
|
||||
{option}`system.nixos.version`).
|
||||
|
||||
Can be overriden by setting <envar>NIXOS_LABEL</envar>.
|
||||
Can be overriden by setting {env}`NIXOS_LABEL`.
|
||||
|
||||
Useful for not loosing track of configurations built from different
|
||||
nixos branches/revisions, e.g.:
|
||||
|
||||
<screen>
|
||||
```
|
||||
#!/bin/sh
|
||||
today=`date +%Y%m%d`
|
||||
branch=`(cd nixpkgs ; git branch 2>/dev/null | sed -n '/^\* / { s|^\* ||; p; }')`
|
||||
revision=`(cd nixpkgs ; git rev-parse HEAD)`
|
||||
export NIXOS_LABEL_VERSION="$today.$branch-''${revision:0:7}"
|
||||
nixos-rebuild switch</screen>
|
||||
nixos-rebuild switch
|
||||
```
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -46,19 +47,19 @@ in
|
|||
type = types.listOf types.str;
|
||||
default = [];
|
||||
example = [ "with-xen" ];
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Strings to prefix to the default
|
||||
<option>system.nixos.label</option>.
|
||||
{option}`system.nixos.label`.
|
||||
|
||||
Useful for not loosing track of configurations built with
|
||||
different options, e.g.:
|
||||
|
||||
<screen>
|
||||
```
|
||||
{
|
||||
system.nixos.tags = [ "with-xen" ];
|
||||
virtualisation.xen.enable = true;
|
||||
}
|
||||
</screen>
|
||||
```
|
||||
'';
|
||||
};
|
||||
|
||||
|
|
|
@ -7,7 +7,7 @@ in
|
|||
{
|
||||
options = {
|
||||
documentation.man.man-db = {
|
||||
enable = lib.mkEnableOption "man-db as the default man page viewer" // {
|
||||
enable = lib.mkEnableOption (lib.mdDoc "man-db as the default man page viewer") // {
|
||||
default = config.documentation.man.enable;
|
||||
defaultText = lib.literalExpression "config.documentation.man.enable";
|
||||
example = false;
|
||||
|
|
|
@ -10,7 +10,7 @@ in {
|
|||
|
||||
options = {
|
||||
documentation.man.mandoc = {
|
||||
enable = lib.mkEnableOption "mandoc as the default man page viewer";
|
||||
enable = lib.mkEnableOption (lib.mdDoc "mandoc as the default man page viewer");
|
||||
|
||||
manPath = lib.mkOption {
|
||||
type = with lib.types; listOf str;
|
||||
|
|
|
@ -38,7 +38,7 @@ in
|
|||
internal = true;
|
||||
default = [];
|
||||
example = literalExpression ''[ lib.maintainers.all ]'';
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
List of maintainers of each module. This option should be defined at
|
||||
most once per module.
|
||||
'';
|
||||
|
@ -48,7 +48,7 @@ in
|
|||
type = docFile;
|
||||
internal = true;
|
||||
example = "./meta.chapter.xml";
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Documentation prologue for the set of options of each module. This
|
||||
option should be defined at most once per module.
|
||||
'';
|
||||
|
@ -60,7 +60,7 @@ in
|
|||
};
|
||||
internal = true;
|
||||
default = true;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
Whether to include this module in the split options doc build.
|
||||
Disable if the module references `config`, `pkgs` or other module
|
||||
arguments that cannot be evaluated as constants.
|
||||
|
|
|
@ -5,7 +5,7 @@ let
|
|||
|
||||
inherit (config.nixops) enableDeprecatedAutoLuks;
|
||||
in {
|
||||
options.nixops.enableDeprecatedAutoLuks = lib.mkEnableOption "Enable the deprecated NixOps AutoLuks module";
|
||||
options.nixops.enableDeprecatedAutoLuks = lib.mkEnableOption (lib.mdDoc "Enable the deprecated NixOps AutoLuks module");
|
||||
|
||||
config = {
|
||||
assertions = [
|
||||
|
|
|
@ -311,26 +311,26 @@ in
|
|||
defaultText = lib.literalMD ''
|
||||
Traditionally `builtins.currentSystem`, but unset when invoking NixOS through `lib.nixosSystem`.
|
||||
'';
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
This option does not need to be specified for NixOS configurations
|
||||
with a recently generated <literal>hardware-configuration.nix</literal>.
|
||||
with a recently generated `hardware-configuration.nix`.
|
||||
|
||||
Specifies the Nix platform type on which NixOS should be built.
|
||||
It is better to specify <literal>nixpkgs.localSystem</literal> instead.
|
||||
<programlisting>
|
||||
It is better to specify `nixpkgs.localSystem` instead.
|
||||
```
|
||||
{
|
||||
nixpkgs.system = ..;
|
||||
}
|
||||
</programlisting>
|
||||
```
|
||||
is the same as
|
||||
<programlisting>
|
||||
```
|
||||
{
|
||||
nixpkgs.localSystem.system = ..;
|
||||
}
|
||||
</programlisting>
|
||||
See <literal>nixpkgs.localSystem</literal> for more information.
|
||||
```
|
||||
See `nixpkgs.localSystem` for more information.
|
||||
|
||||
Ignored when <literal>nixpkgs.pkgs</literal>, <literal>nixpkgs.localSystem</literal> or <literal>nixpkgs.hostPlatform</literal> is set.
|
||||
Ignored when `nixpkgs.pkgs`, `nixpkgs.localSystem` or `nixpkgs.hostPlatform` is set.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
options = {
|
||||
passthru = lib.mkOption {
|
||||
visible = false;
|
||||
description = ''
|
||||
description = lib.mdDoc ''
|
||||
This attribute set will be exported as a system attribute.
|
||||
You can put whatever you want here.
|
||||
'';
|
||||
|
|
|
@ -8,7 +8,7 @@ in
|
|||
{
|
||||
options = {
|
||||
environment.wordlist = {
|
||||
enable = mkEnableOption "environment variables for lists of words";
|
||||
enable = mkEnableOption (lib.mdDoc "environment variables for lists of words");
|
||||
|
||||
lists = mkOption {
|
||||
type = types.attrsOf (types.nonEmptyListOf types.path);
|
||||
|
|
|
@ -16,7 +16,7 @@ in
|
|||
|
||||
options = {
|
||||
programs._1password-gui = {
|
||||
enable = mkEnableOption "the 1Password GUI application";
|
||||
enable = mkEnableOption (lib.mdDoc "the 1Password GUI application");
|
||||
|
||||
polkitPolicyOwners = mkOption {
|
||||
type = types.listOf types.str;
|
||||
|
|
|
@ -16,7 +16,7 @@ in
|
|||
|
||||
options = {
|
||||
programs._1password = {
|
||||
enable = mkEnableOption "the 1Password CLI tool";
|
||||
enable = mkEnableOption (lib.mdDoc "the 1Password CLI tool");
|
||||
|
||||
package = mkPackageOption pkgs "1Password CLI" {
|
||||
default = [ "_1password" ];
|
||||
|
|
|
@ -5,7 +5,7 @@ with lib;
|
|||
{
|
||||
options = {
|
||||
programs.appgate-sdp = {
|
||||
enable = mkEnableOption "AppGate SDP VPN client";
|
||||
enable = mkEnableOption (lib.mdDoc "AppGate SDP VPN client");
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ in
|
|||
|
||||
programs.atop = rec {
|
||||
|
||||
enable = mkEnableOption "Atop";
|
||||
enable = mkEnableOption (lib.mdDoc "Atop");
|
||||
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
|
|
|
@ -13,7 +13,7 @@ in
|
|||
{
|
||||
options = {
|
||||
programs.bash-my-aws = {
|
||||
enable = mkEnableOption "bash-my-aws";
|
||||
enable = mkEnableOption (lib.mdDoc "bash-my-aws");
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -7,7 +7,7 @@ let
|
|||
in
|
||||
{
|
||||
options = {
|
||||
programs.bash.enableCompletion = mkEnableOption "Bash completion for all interactive bash shells" // {
|
||||
programs.bash.enableCompletion = mkEnableOption (lib.mdDoc "Bash completion for all interactive bash shells") // {
|
||||
default = true;
|
||||
};
|
||||
};
|
||||
|
|
|
@ -7,7 +7,7 @@ let
|
|||
in
|
||||
{
|
||||
options = {
|
||||
programs.bash.enableLsColors = mkEnableOption "extra colors in directory listings" // {
|
||||
programs.bash.enableLsColors = mkEnableOption (lib.mdDoc "extra colors in directory listings") // {
|
||||
default = true;
|
||||
};
|
||||
};
|
||||
|
|
|
@ -8,9 +8,9 @@ in
|
|||
{
|
||||
options = {
|
||||
programs.bash.undistractMe = {
|
||||
enable = mkEnableOption "notifications when long-running terminal commands complete";
|
||||
enable = mkEnableOption (lib.mdDoc "notifications when long-running terminal commands complete");
|
||||
|
||||
playSound = mkEnableOption "notification sounds when long-running terminal commands complete";
|
||||
playSound = mkEnableOption (lib.mdDoc "notification sounds when long-running terminal commands complete");
|
||||
|
||||
timeout = mkOption {
|
||||
default = 10;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
{
|
||||
options.programs.bcc.enable = lib.mkEnableOption "bcc";
|
||||
options.programs.bcc.enable = lib.mkEnableOption (lib.mdDoc "bcc");
|
||||
|
||||
config = lib.mkIf config.programs.bcc.enable {
|
||||
environment.systemPackages = [ pkgs.bcc ];
|
||||
|
|
|
@ -4,7 +4,7 @@ with lib;
|
|||
|
||||
{
|
||||
|
||||
options.programs.browserpass.enable = mkEnableOption "Browserpass native messaging host";
|
||||
options.programs.browserpass.enable = mkEnableOption (lib.mdDoc "Browserpass native messaging host");
|
||||
|
||||
config = mkIf config.programs.browserpass.enable {
|
||||
environment.etc = let
|
||||
|
|
|
@ -7,9 +7,9 @@ let
|
|||
in {
|
||||
options = {
|
||||
programs.calls = {
|
||||
enable = mkEnableOption ''
|
||||
enable = mkEnableOption (lib.mdDoc ''
|
||||
Whether to enable GNOME calls: a phone dialer and call handler.
|
||||
'';
|
||||
'');
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -34,7 +34,7 @@ in
|
|||
|
||||
options = {
|
||||
programs.captive-browser = {
|
||||
enable = mkEnableOption "captive browser";
|
||||
enable = mkEnableOption (lib.mdDoc "captive browser");
|
||||
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
|
|
|
@ -6,7 +6,7 @@ let
|
|||
in {
|
||||
options.programs.ccache = {
|
||||
# host configuration
|
||||
enable = mkEnableOption "CCache";
|
||||
enable = mkEnableOption (lib.mdDoc "CCache");
|
||||
cacheDir = mkOption {
|
||||
type = types.path;
|
||||
description = lib.mdDoc "CCache directory";
|
||||
|
|
|
@ -17,7 +17,7 @@ in
|
|||
};
|
||||
|
||||
options = {
|
||||
programs.cfs-zen-tweaks.enable = mkEnableOption "CFS Zen Tweaks";
|
||||
programs.cfs-zen-tweaks.enable = mkEnableOption (lib.mdDoc "CFS Zen Tweaks");
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
|
|
@ -19,7 +19,7 @@ in
|
|||
|
||||
options = {
|
||||
programs.chromium = {
|
||||
enable = mkEnableOption "<command>chromium</command> policies";
|
||||
enable = mkEnableOption (lib.mdDoc "{command}`chromium` policies");
|
||||
|
||||
extensions = mkOption {
|
||||
type = types.listOf types.str;
|
||||
|
|
|
@ -8,7 +8,7 @@ in
|
|||
{
|
||||
options = {
|
||||
programs.cnping = {
|
||||
enable = mkEnableOption "Whether to install a setcap wrapper for cnping";
|
||||
enable = mkEnableOption (lib.mdDoc "Whether to install a setcap wrapper for cnping");
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@ in
|
|||
|
||||
options = {
|
||||
programs.dconf = {
|
||||
enable = mkEnableOption "dconf";
|
||||
enable = mkEnableOption (lib.mdDoc "dconf");
|
||||
|
||||
profiles = mkOption {
|
||||
type = types.attrsOf types.path;
|
||||
|
|
|
@ -4,7 +4,7 @@ with lib;
|
|||
|
||||
{
|
||||
options.programs.droidcam = {
|
||||
enable = mkEnableOption "DroidCam client";
|
||||
enable = mkEnableOption (lib.mdDoc "DroidCam client");
|
||||
};
|
||||
|
||||
config = lib.mkIf config.programs.droidcam.enable {
|
||||
|
|
|
@ -22,7 +22,7 @@ in {
|
|||
programs.evince = {
|
||||
|
||||
enable = mkEnableOption
|
||||
"Evince, the GNOME document viewer";
|
||||
(lib.mdDoc "Evince, the GNOME document viewer");
|
||||
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
|
|
|
@ -5,10 +5,10 @@ let
|
|||
cfg = config.programs.extra-container;
|
||||
in {
|
||||
options = {
|
||||
programs.extra-container.enable = mkEnableOption ''
|
||||
programs.extra-container.enable = mkEnableOption (lib.mdDoc ''
|
||||
extra-container, a tool for running declarative NixOS containers
|
||||
without host system rebuilds
|
||||
'';
|
||||
'');
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
environment.systemPackages = [ pkgs.extra-container ];
|
||||
|
|
|
@ -7,11 +7,11 @@ let
|
|||
in {
|
||||
options = {
|
||||
programs.feedbackd = {
|
||||
enable = mkEnableOption ''
|
||||
enable = mkEnableOption (lib.mdDoc ''
|
||||
Whether to enable the feedbackd D-BUS service and udev rules.
|
||||
|
||||
Your user needs to be in the `feedbackd` group to trigger effects.
|
||||
'';
|
||||
'');
|
||||
package = mkOption {
|
||||
description = lib.mdDoc ''
|
||||
Which feedbackd package to use.
|
||||
|
|
|
@ -21,7 +21,7 @@ in {
|
|||
|
||||
programs.file-roller = {
|
||||
|
||||
enable = mkEnableOption "File Roller, an archive manager for GNOME";
|
||||
enable = mkEnableOption (lib.mdDoc "File Roller, an archive manager for GNOME");
|
||||
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
|
|
|
@ -32,26 +32,26 @@ let
|
|||
|
||||
in {
|
||||
options.programs.firejail = {
|
||||
enable = mkEnableOption "firejail";
|
||||
enable = mkEnableOption (lib.mdDoc "firejail");
|
||||
|
||||
wrappedBinaries = mkOption {
|
||||
type = types.attrsOf (types.either types.path (types.submodule {
|
||||
options = {
|
||||
executable = mkOption {
|
||||
type = types.path;
|
||||
description = "Executable to run sandboxed";
|
||||
description = lib.mdDoc "Executable to run sandboxed";
|
||||
example = literalExpression ''"''${lib.getBin pkgs.firefox}/bin/firefox"'';
|
||||
};
|
||||
profile = mkOption {
|
||||
type = types.nullOr types.path;
|
||||
default = null;
|
||||
description = "Profile to use";
|
||||
description = lib.mdDoc "Profile to use";
|
||||
example = literalExpression ''"''${pkgs.firejail}/etc/firejail/firefox.profile"'';
|
||||
};
|
||||
extraArgs = mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = [];
|
||||
description = "Extra arguments to pass to firejail";
|
||||
description = lib.mdDoc "Extra arguments to pass to firejail";
|
||||
example = [ "--private=~/.firejail_home" ];
|
||||
};
|
||||
};
|
||||
|
|
|
@ -7,7 +7,7 @@ let
|
|||
in {
|
||||
options = {
|
||||
programs.flexoptix-app = {
|
||||
enable = mkEnableOption "FLEXOPTIX app + udev rules";
|
||||
enable = mkEnableOption (lib.mdDoc "FLEXOPTIX app + udev rules");
|
||||
|
||||
package = mkOption {
|
||||
description = lib.mdDoc "FLEXOPTIX app package to use";
|
||||
|
|
|
@ -10,9 +10,9 @@ in
|
|||
{
|
||||
options = {
|
||||
programs.gamemode = {
|
||||
enable = mkEnableOption "GameMode to optimise system performance on demand";
|
||||
enable = mkEnableOption (lib.mdDoc "GameMode to optimise system performance on demand");
|
||||
|
||||
enableRenice = mkEnableOption "CAP_SYS_NICE on gamemoded to support lowering process niceness" // {
|
||||
enableRenice = mkEnableOption (lib.mdDoc "CAP_SYS_NICE on gamemoded to support lowering process niceness") // {
|
||||
default = true;
|
||||
};
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@ in {
|
|||
};
|
||||
|
||||
options = {
|
||||
programs.geary.enable = mkEnableOption "Geary, a Mail client for GNOME 3";
|
||||
programs.geary.enable = mkEnableOption (lib.mdDoc "Geary, a Mail client for GNOME 3");
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
|
|
@ -9,7 +9,7 @@ in
|
|||
{
|
||||
options = {
|
||||
programs.git = {
|
||||
enable = mkEnableOption "git";
|
||||
enable = mkEnableOption (lib.mdDoc "git");
|
||||
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
|
@ -33,7 +33,7 @@ in
|
|||
};
|
||||
|
||||
lfs = {
|
||||
enable = mkEnableOption "git-lfs";
|
||||
enable = mkEnableOption (lib.mdDoc "git-lfs");
|
||||
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
|
|
|
@ -24,7 +24,7 @@ in
|
|||
];
|
||||
|
||||
options = {
|
||||
programs.gnome-terminal.enable = mkEnableOption "GNOME Terminal";
|
||||
programs.gnome-terminal.enable = mkEnableOption (lib.mdDoc "GNOME Terminal");
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
|
|
@ -4,7 +4,7 @@ with lib;
|
|||
|
||||
{
|
||||
options.programs.haguichi = {
|
||||
enable = mkEnableOption "Haguichi, a Linux GUI frontend to the proprietary LogMeIn Hamachi";
|
||||
enable = mkEnableOption (lib.mdDoc "Haguichi, a Linux GUI frontend to the proprietary LogMeIn Hamachi");
|
||||
};
|
||||
|
||||
config = mkIf config.programs.haguichi.enable {
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue