mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-16 18:03:59 +00:00
46 lines
1.6 KiB
XML
46 lines
1.6 KiB
XML
<!-- Do not edit this file directly, edit its companion .md instead
|
|
and regenerate this file using nixos/doc/manual/md-to-db.sh -->
|
|
<chapter xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xml:id="module-services-plausible">
|
|
<title>Plausible</title>
|
|
<para>
|
|
<link xlink:href="https://plausible.io/">Plausible</link> is a
|
|
privacy-friendly alternative to Google analytics.
|
|
</para>
|
|
<section xml:id="module-services-plausible-basic-usage">
|
|
<title>Basic Usage</title>
|
|
<para>
|
|
At first, a secret key is needed to be generated. This can be done
|
|
with e.g.
|
|
</para>
|
|
<programlisting>
|
|
$ openssl rand -base64 64
|
|
</programlisting>
|
|
<para>
|
|
After that, <literal>plausible</literal> can be deployed like
|
|
this:
|
|
</para>
|
|
<programlisting>
|
|
{
|
|
services.plausible = {
|
|
enable = true;
|
|
adminUser = {
|
|
# activate is used to skip the email verification of the admin-user that's
|
|
# automatically created by plausible. This is only supported if
|
|
# postgresql is configured by the module. This is done by default, but
|
|
# can be turned off with services.plausible.database.postgres.setup.
|
|
activate = true;
|
|
email = "admin@localhost";
|
|
passwordFile = "/run/secrets/plausible-admin-pwd";
|
|
};
|
|
server = {
|
|
baseUrl = "http://analytics.example.org";
|
|
# secretKeybaseFile is a path to the file which contains the secret generated
|
|
# with openssl as described above.
|
|
secretKeybaseFile = "/run/secrets/plausible-secret-key-base";
|
|
};
|
|
};
|
|
}
|
|
</programlisting>
|
|
</section>
|
|
</chapter>
|