···8 <subtitle>Version <xi:include href="./generated/version" parse="text" />
9 </subtitle>
10 </info>
11- <preface>
12 <title>Preface</title>
13 <para>
14 This manual describes how to install, use and extend NixOS, a Linux
···8 <subtitle>Version <xi:include href="./generated/version" parse="text" />
9 </subtitle>
10 </info>
11+ <preface xml:id="preface">
12 <title>Preface</title>
13 <para>
14 This manual describes how to install, use and extend NixOS, a Linux
···23 bridge.</para></listitem>
24</itemizedlist>
2526-<section><title>IBus</title>
2728<para>IBus is an Intelligent Input Bus. It provides full featured and user
29 friendly input method user interface.</para>
···82</simplesect>
83</section>
8485-<section><title>Fcitx</title>
8687<para>Fcitx is an input method framework with extension support. It has three
88 built-in Input Method Engine, Pinyin, QuWei and Table-based input
···122</itemizedlist>
123</section>
124125-<section><title>Nabi</title>
126127<para>Nabi is an easy to use Korean X input method. It allows you to enter
128 phonetic Korean characters (hangul) and pictographic Korean characters
···136</programlisting>
137</section>
138139-<section><title>Uim</title>
140141<para>Uim (short for "universal input method") is a multilingual input method
142 framework. Applications can use it through so-called bridges.</para>
···23 bridge.</para></listitem>
24</itemizedlist>
2526+<section xml:id="module-services-input-methods-ibus"><title>IBus</title>
2728<para>IBus is an Intelligent Input Bus. It provides full featured and user
29 friendly input method user interface.</para>
···82</simplesect>
83</section>
8485+<section xml:id="module-services-input-methods-fcitx"><title>Fcitx</title>
8687<para>Fcitx is an input method framework with extension support. It has three
88 built-in Input Method Engine, Pinyin, QuWei and Table-based input
···122</itemizedlist>
123</section>
124125+<section xml:id="module-services-input-methods-nabi"><title>Nabi</title>
126127<para>Nabi is an easy to use Korean X input method. It allows you to enter
128 phonetic Korean characters (hangul) and pictographic Korean characters
···136</programlisting>
137</section>
138139+<section xml:id="module-services-input-methods-uim"><title>Uim</title>
140141<para>Uim (short for "universal input method") is a multilingual input method
142 framework. Applications can use it through so-called bridges.</para>
+4-4
nixos/modules/programs/zsh/oh-my-zsh.xml
···10to manage your <link xlink:href="https://www.zsh.org/">ZSH</link> configuration
11including completion scripts for several CLI tools or custom prompt themes.</para>
1213-<section><title>Basic usage</title>
14<para>The module uses the <literal>oh-my-zsh</literal> package with all available features. The
15initial setup using Nix expressions is fairly similar to the configuration format
16of <literal>oh-my-zsh</literal>.
···32configuration and writes it into your <literal>/etc/zshrc</literal>.
33</para></section>
3435-<section><title>Custom additions</title>
3637<para>Sometimes third-party or custom scripts such as a modified theme may be needed.
38<literal>oh-my-zsh</literal> provides the
···48</programlisting>
49</para></section>
5051-<section><title>Custom environments</title>
5253<para>There are several extensions for <literal>oh-my-zsh</literal> packaged in <literal>nixpkgs</literal>.
54One of them is <link xlink:href="https://github.com/spwhitt/nix-zsh-completions">nix-zsh-completions</link>
···77will be thrown if both <literal>custom</literal> and <literal>customPkgs</literal> are set.</emphasis>
78</para></section>
7980-<section><title>Package your own customizations</title>
8182<para>If third-party customizations (e.g. new themes) are supposed to be added to <literal>oh-my-zsh</literal>
83there are several pitfalls to keep in mind:</para>
···10to manage your <link xlink:href="https://www.zsh.org/">ZSH</link> configuration
11including completion scripts for several CLI tools or custom prompt themes.</para>
1213+<section xml:id="module-programs-oh-my-zsh-usage"><title>Basic usage</title>
14<para>The module uses the <literal>oh-my-zsh</literal> package with all available features. The
15initial setup using Nix expressions is fairly similar to the configuration format
16of <literal>oh-my-zsh</literal>.
···32configuration and writes it into your <literal>/etc/zshrc</literal>.
33</para></section>
3435+<section xml:id="module-programs-oh-my-zsh-additions"><title>Custom additions</title>
3637<para>Sometimes third-party or custom scripts such as a modified theme may be needed.
38<literal>oh-my-zsh</literal> provides the
···48</programlisting>
49</para></section>
5051+<section xml:id="module-programs-oh-my-zsh-environments"><title>Custom environments</title>
5253<para>There are several extensions for <literal>oh-my-zsh</literal> packaged in <literal>nixpkgs</literal>.
54One of them is <link xlink:href="https://github.com/spwhitt/nix-zsh-completions">nix-zsh-completions</link>
···77will be thrown if both <literal>custom</literal> and <literal>customPkgs</literal> are set.</emphasis>
78</para></section>
7980+<section xml:id="module-programs-oh-my-zsh-packaging-customizations"><title>Package your own customizations</title>
8182<para>If third-party customizations (e.g. new themes) are supposed to be added to <literal>oh-my-zsh</literal>
83there are several pitfalls to keep in mind:</para>
+3-3
nixos/modules/security/acme.xml
···11implemented by and for Let's Encrypt. The alternative ACME client
12<literal>simp_le</literal> is used under the hood.</para>
1314-<section><title>Prerequisites</title>
1516<para>You need to have a running HTTP server for verification. The server must
17have a webroot defined that can serve
···4142</section>
4344-<section><title>Configuring</title>
4546<para>To enable ACME certificate retrieval & renewal for a certificate for
47<literal>foo.example.com</literal>, add the following in your
···6667</section>
6869-<section><title>Using ACME certificates in Nginx</title>
70<para>NixOS supports fetching ACME certificates for you by setting
71 <literal><link linkend="opt-services.nginx.virtualHosts._name_.enableACME">enableACME</link> = true;</literal> in a virtualHost config. We
72first create self-signed placeholder certificates in place of the
···11implemented by and for Let's Encrypt. The alternative ACME client
12<literal>simp_le</literal> is used under the hood.</para>
1314+<section xml:id="module-security-acme-prerequisites"><title>Prerequisites</title>
1516<para>You need to have a running HTTP server for verification. The server must
17have a webroot defined that can serve
···4142</section>
4344+<section xml:id="module-security-acme-configuring"><title>Configuring</title>
4546<para>To enable ACME certificate retrieval & renewal for a certificate for
47<literal>foo.example.com</literal>, add the following in your
···6667</section>
6869+<section xml:id="module-security-acme-nginx"><title>Using ACME certificates in Nginx</title>
70<para>NixOS supports fetching ACME certificates for you by setting
71 <literal><link linkend="opt-services.nginx.virtualHosts._name_.enableACME">enableACME</link> = true;</literal> in a virtualHost config. We
72first create self-signed placeholder certificates in place of the
+9-9
nixos/modules/services/databases/foundationdb.xml
···17<para>FoundationDB (or "FDB") is an open source, distributed, transactional
18key-value store.</para>
1920-<section><title>Configuring and basic setup</title>
2122<para>To enable FoundationDB, add the following to your
23<filename>configuration.nix</filename>:
···133134</section>
135136-<section><title>Scaling processes and backup agents</title>
137138<para>Scaling the number of server processes is quite easy; simply specify
139<option>services.foundationdb.serverProcesses</option> to be the number of
···151152</section>
153154-<section><title>Clustering</title>
155156<para>FoundationDB on NixOS works similarly to other Linux systems, so this
157section will be brief. Please refer to the full FoundationDB documentation for
···221222</section>
223224-<section><title>Client connectivity</title>
225226<para>By default, all clients must use the current
227<command>fdb.cluster</command> file to access a given FoundationDB cluster.
···232233</section>
234235-<section><title>Client authorization and TLS</title>
236237<para>By default, any user who can connect to a FoundationDB process with the
238correct cluster configuration can access anything. FoundationDB uses a
···270271</section>
272273-<section><title>Backups and Disaster Recovery</title>
274275<para>The usual rules for doing FoundationDB backups apply on NixOS as written
276in the FoundationDB manual. However, one important difference is the security
···316317</section>
318319-<section><title>Known limitations</title>
320321<para>The FoundationDB setup for NixOS should currently be considered beta.
322FoundationDB is not new software, but the NixOS compilation and integration has
···333334</section>
335336-<section><title>Options</title>
337338<para>NixOS's FoundationDB module allows you to configure all of the most
339relevant configuration options for <command>fdbmonitor</command>, matching it
···343344</section>
345346-<section><title>Full documentation</title>
347348<para>FoundationDB is a complex piece of software, and requires careful
349administration to properly use. Full documentation for administration can be
···17<para>FoundationDB (or "FDB") is an open source, distributed, transactional
18key-value store.</para>
1920+<section xml:id="module-services-foundationdb-configuring"><title>Configuring and basic setup</title>
2122<para>To enable FoundationDB, add the following to your
23<filename>configuration.nix</filename>:
···133134</section>
135136+<section xml:id="module-services-foundationdb-scaling"><title>Scaling processes and backup agents</title>
137138<para>Scaling the number of server processes is quite easy; simply specify
139<option>services.foundationdb.serverProcesses</option> to be the number of
···151152</section>
153154+<section xml:id="module-services-foundationdb-clustering"><title>Clustering</title>
155156<para>FoundationDB on NixOS works similarly to other Linux systems, so this
157section will be brief. Please refer to the full FoundationDB documentation for
···221222</section>
223224+<section xml:id="module-services-foundationdb-connectivity"><title>Client connectivity</title>
225226<para>By default, all clients must use the current
227<command>fdb.cluster</command> file to access a given FoundationDB cluster.
···232233</section>
234235+<section xml:id="module-services-foundationdb-authorization"><title>Client authorization and TLS</title>
236237<para>By default, any user who can connect to a FoundationDB process with the
238correct cluster configuration can access anything. FoundationDB uses a
···270271</section>
272273+<section xml:id="module-services-foundationdb-disaster-recovery"><title>Backups and Disaster Recovery</title>
274275<para>The usual rules for doing FoundationDB backups apply on NixOS as written
276in the FoundationDB manual. However, one important difference is the security
···316317</section>
318319+<section xml:id="module-services-foundationdb-limitations"><title>Known limitations</title>
320321<para>The FoundationDB setup for NixOS should currently be considered beta.
322FoundationDB is not new software, but the NixOS compilation and integration has
···333334</section>
335336+<section xml:id="module-services-foundationdb-options"><title>Options</title>
337338<para>NixOS's FoundationDB module allows you to configure all of the most
339relevant configuration options for <command>fdbmonitor</command>, matching it
···343344</section>
345346+<section xml:id="module-services-foundationdb-full-docs"><title>Full documentation</title>
347348<para>FoundationDB is a complex piece of software, and requires careful
349administration to properly use. Full documentation for administration can be
+3-3
nixos/modules/services/databases/postgresql.xml
···1718<para>PostgreSQL is an advanced, free relational database.<!-- MORE --></para>
1920-<section><title>Configuring</title>
2122<para>To enable PostgreSQL, add the following to your
23<filename>configuration.nix</filename>:
···60</section>
616263-<section><title>Upgrading</title>
6465<para>FIXME: document dump/upgrade/load cycle.</para>
6667</section>
686970-<section><title>Options</title>
7172 <para>A complete list of options for the PostgreSQL module may be found <link linkend="opt-services.postgresql.enable">here</link>.</para>
73
···1718<para>PostgreSQL is an advanced, free relational database.<!-- MORE --></para>
1920+<section xml:id="module-services-postgres-configuring"><title>Configuring</title>
2122<para>To enable PostgreSQL, add the following to your
23<filename>configuration.nix</filename>:
···60</section>
616263+<section xml:id="module-services-postgres-upgrading"><title>Upgrading</title>
6465<para>FIXME: document dump/upgrade/load cycle.</para>
6667</section>
686970+<section xml:id="module-services-postgres-options"><title>Options</title>
7172 <para>A complete list of options for the PostgreSQL module may be found <link linkend="opt-services.postgresql.enable">here</link>.</para>
73
+12-12
nixos/modules/services/editors/emacs.xml
···39 starting the Emacs daemon.
40 </para>
4142- <section>
43 <title>Installing <application>Emacs</application></title>
4445 <para>
···49 can be enabled.
50 </para>
5152- <section>
53 <title>The Different Releases of Emacs</title>
5455 <para>
···100 </para>
101102 </section>
103- <section>
104 <title>Adding Packages to Emacs</title>
105 <para>
106 Emacs includes an entire ecosystem of functionality beyond
···339 </para>
340 </section>
341342- <section>
343 <title>Advanced Emacs Configuration</title>
344345 <para>
···380 </section>
381 </section>
382383-<section>
384 <title>Running Emacs as a Service</title>
385 <para>
386 <productname>NixOS</productname> provides an optional
···396 <filename>modules/services/editors/emacs.nix</filename>
397 </para>
398399- <section>
400 <title>Enabling the Service</title>
401402 <para>
···438439 </section>
440441- <section>
442 <title>Starting the client</title>
443 <para>
444 Ensure that the emacs server is enabled, either by customizing
···457 </para>
458 </section>
459460- <section>
461 <title>Configuring the <varname>EDITOR</varname> variable</title>
462 <!--<title><command>emacsclient</command> as the Default Editor</title>-->
463···487 </para>
488 </section>
489490- <section>
491 <title>Per-User Enabling of the Service</title>
492493 <para>
···515 </section>
516</section>
517518-<section>
519 <title>Configuring Emacs</title>
520521 <para>
···548 server-switch-hook, server-done-hook?
549 -->
550551- <section>
552 <title>A Major Mode for Nix Expressions</title>
553554 <para>
···558 </para>
559 </section>
560561- <section>
562 <title>Accessing man pages</title>
563 <para>
564 You can use <function>woman</function> to get completion of all
···39 starting the Emacs daemon.
40 </para>
4142+ <section xml:id="module-services-emacs-installing">
43 <title>Installing <application>Emacs</application></title>
4445 <para>
···49 can be enabled.
50 </para>
5152+ <section xml:id="module-services-emacs-releases">
53 <title>The Different Releases of Emacs</title>
5455 <para>
···100 </para>
101102 </section>
103+ <section xml:id="module-services-emacs-adding-packages">
104 <title>Adding Packages to Emacs</title>
105 <para>
106 Emacs includes an entire ecosystem of functionality beyond
···339 </para>
340 </section>
341342+ <section xml:id="module-services-emacs-advanced">
343 <title>Advanced Emacs Configuration</title>
344345 <para>
···380 </section>
381 </section>
382383+<section xml:id="module-services-emacs-running">
384 <title>Running Emacs as a Service</title>
385 <para>
386 <productname>NixOS</productname> provides an optional
···396 <filename>modules/services/editors/emacs.nix</filename>
397 </para>
398399+ <section xml:id="module-services-emacs-enabling">
400 <title>Enabling the Service</title>
401402 <para>
···438439 </section>
440441+ <section xml:id="module-services-emacs-starting-client">
442 <title>Starting the client</title>
443 <para>
444 Ensure that the emacs server is enabled, either by customizing
···457 </para>
458 </section>
459460+ <section xml:id="module-services-emacs-editor-variable">
461 <title>Configuring the <varname>EDITOR</varname> variable</title>
462 <!--<title><command>emacsclient</command> as the Default Editor</title>-->
463···487 </para>
488 </section>
489490+ <section xml:id="module-services-emacs-per-user">
491 <title>Per-User Enabling of the Service</title>
492493 <para>
···515 </section>
516</section>
517518+<section xml:id="module-services-emacs-configuring">
519 <title>Configuring Emacs</title>
520521 <para>
···548 server-switch-hook, server-done-hook?
549 -->
550551+ <section xml:id="module-services-emacs-major-mode">
552 <title>A Major Mode for Nix Expressions</title>
553554 <para>
···558 </para>
559 </section>
560561+ <section xml:id="module-services-emacs-man-pages">
562 <title>Accessing man pages</title>
563 <para>
564 You can use <function>woman</function> to get completion of all
+3-3
nixos/modules/services/misc/gitlab.xml
···89<para>Gitlab is a feature-rich git hosting service.</para>
1011-<section><title>Prerequisites</title>
1213<para>The gitlab service exposes only an Unix socket at
14<literal>/run/gitlab/gitlab-workhorse.socket</literal>. You need to configure a
···3536</section>
3738-<section><title>Configuring</title>
3940<para>Gitlab depends on both PostgreSQL and Redis and will automatically enable
41both services. In the case of PostgreSQL, a database and a role will be created.
···119120</section>
121122-<section><title>Maintenance</title>
123124<para>You can run Gitlab's rake tasks with <literal>gitlab-rake</literal>
125which will be available on the system when gitlab is enabled. You will
···89<para>Gitlab is a feature-rich git hosting service.</para>
1011+<section xml:id="module-services-gitlab-prerequisites"><title>Prerequisites</title>
1213<para>The gitlab service exposes only an Unix socket at
14<literal>/run/gitlab/gitlab-workhorse.socket</literal>. You need to configure a
···3536</section>
3738+<section xml:id="module-services-gitlab-configuring"><title>Configuring</title>
3940<para>Gitlab depends on both PostgreSQL and Redis and will automatically enable
41both services. In the case of PostgreSQL, a database and a role will be created.
···119120</section>
121122+<section xml:id="module-services-gitlab-maintenance"><title>Maintenance</title>
123124<para>You can run Gitlab's rake tasks with <literal>gitlab-rake</literal>
125which will be available on the system when gitlab is enabled. You will
···89<para>Prometheus exporters provide metrics for the <link xlink:href="https://prometheus.io">prometheus monitoring system</link>.</para>
1011-<section><title>Configuration</title>
12 <para>One of the most common exporters is the <link xlink:href="https://github.com/prometheus/node_exporter">node exporter</link>, it provides hardware and OS metrics from the host it's running on. The exporter could be configured as follows:
13<programlisting>
14 services.promtheus.exporters.node = {
···33search through the <link xlink:href="https://nixos.org/nixos/options.html#prometheus.exporters">available options</link>.
34</para>
35</section>
36-<section><title>Adding a new exporter</title>
37 <para>To add a new exporter, it has to be packaged first (see <literal>nixpkgs/pkgs/servers/monitoring/prometheus/</literal> for examples), then a module can be added. The postfix exporter is used in this example:</para>
38<itemizedlist>
39 <listitem>
···89<para>Prometheus exporters provide metrics for the <link xlink:href="https://prometheus.io">prometheus monitoring system</link>.</para>
1011+<section xml:id="module-services-prometheus-exporters-configuration"><title>Configuration</title>
12 <para>One of the most common exporters is the <link xlink:href="https://github.com/prometheus/node_exporter">node exporter</link>, it provides hardware and OS metrics from the host it's running on. The exporter could be configured as follows:
13<programlisting>
14 services.promtheus.exporters.node = {
···33search through the <link xlink:href="https://nixos.org/nixos/options.html#prometheus.exporters">available options</link>.
34</para>
35</section>
36+<section xml:id="module-services-prometheus-exporters-new-exporter"><title>Adding a new exporter</title>
37 <para>To add a new exporter, it has to be packaged first (see <literal>nixpkgs/pkgs/servers/monitoring/prometheus/</literal> for examples), then a module can be added. The postfix exporter is used in this example:</para>
38<itemizedlist>
39 <listitem>
···14 upstream is trustworthy).
15 </para>
1617- <sect1><title>Basic configuration</title>
1819 <para>
20 To enable the client proxy, set
···3132 </sect1>
3334- <sect1><title>As a forwarder for another DNS client</title>
3536 <para>
37 To run the DNSCrypt proxy client as a forwarder for another
···42 </programlisting>
43 </para>
4445- <sect2><title>dnsmasq</title>
46 <para>
47 <programlisting>
48{
···53 </para>
54 </sect2>
5556- <sect2><title>unbound</title>
57 <para>
58 <programlisting>
59{
···14 upstream is trustworthy).
15 </para>
1617+ <sect1 xml:id="sec-dnscrypt-proxy-configuration"><title>Basic configuration</title>
1819 <para>
20 To enable the client proxy, set
···3132 </sect1>
3334+ <sect1 xml:id="sec-dnscrypt-proxy-forwarder"><title>As a forwarder for another DNS client</title>
3536 <para>
37 To run the DNSCrypt proxy client as a forwarder for another
···42 </programlisting>
43 </para>
4445+ <sect2 xml:id="sec-dnscrypt-proxy-forwarder-dsnmasq"><title>dnsmasq</title>
46 <para>
47 <programlisting>
48{
···53 </para>
54 </sect2>
5556+ <sect2 xml:id="sec-dnscrypt-proxy-forwarder-unbound"><title>unbound</title>
57 <para>
58 <programlisting>
59{
+4-4
nixos/modules/services/web-apps/matomo-doc.xml
···15 </para>
161718- <section>
19 <title>Database Setup</title>
2021 <para>
···51 </section>
525354- <section>
55 <title>Backup</title>
56 <para>
57 You only need to take backups of your MySQL database and the
···62 </section>
636465- <section>
66 <title>Issues</title>
67 <itemizedlist>
68 <listitem>
···83 </section>
848586- <section>
87 <title>Using other Web Servers than nginx</title>
8889 <para>
···15 </para>
161718+ <section xml:id="module-services-matomo-database-setup">
19 <title>Database Setup</title>
2021 <para>
···51 </section>
525354+ <section xml:id="module-services-matomo-backups">
55 <title>Backup</title>
56 <para>
57 You only need to take backups of your MySQL database and the
···62 </section>
636465+ <section xml:id="module-services-matomo-issues">
66 <title>Issues</title>
67 <itemizedlist>
68 <listitem>
···83 </section>
848586+ <section xml:id="module-services-matomo-other-web-servers">
87 <title>Using other Web Servers than nginx</title>
8889 <para>