Skip to content
This repository was archived by the owner on Apr 12, 2021. It is now read-only.
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs-channels
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: ab3adfe1c769
Choose a base ref
...
head repository: NixOS/nixpkgs-channels
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 4d373182597c
Choose a head ref
Loading
Showing with 2,057 additions and 1,208 deletions.
  1. +4 −4 nixos/modules/security/acme.nix
  2. +202 −45 nixos/modules/security/acme.xml
  3. +1 −1 nixos/modules/services/x11/desktop-managers/pantheon.xml
  4. +2 −3 pkgs/applications/misc/st/default.nix
  5. +49 −13 pkgs/applications/misc/terminator/default.nix
  6. +9 −9 pkgs/applications/networking/browsers/chromium/upstream-info.nix
  7. +385 −385 pkgs/applications/networking/browsers/firefox-bin/beta_sources.nix
  8. +385 −385 pkgs/applications/networking/browsers/firefox-bin/release_sources.nix
  9. +2 −2 pkgs/applications/networking/browsers/firefox/common.nix
  10. +23 −0 pkgs/applications/networking/browsers/firefox/no-buildconfig-ffx76.patch
  11. +5 −5 pkgs/applications/networking/browsers/firefox/packages.nix
  12. +0 −26 pkgs/applications/networking/cluster/kubeval/default.nix
  13. +15 −0 pkgs/applications/networking/cluster/kubeval/schema.nix
  14. +3 −2 pkgs/applications/networking/instant-messengers/skypeforlinux/default.nix
  15. +9 −9 pkgs/applications/networking/instant-messengers/zoom-us/default.nix
  16. +5 −12 pkgs/applications/networking/mailreaders/neomutt/default.nix
  17. +3 −3 pkgs/applications/networking/p2p/tribler/default.nix
  18. +2 −2 pkgs/applications/networking/sniffers/wireshark/default.nix
  19. +2 −2 pkgs/applications/office/softmaker/softmaker_office.nix
  20. +4 −4 pkgs/applications/version-management/gitlab/data.json
  21. +2 −2 pkgs/applications/version-management/gitlab/gitaly/Gemfile.lock
  22. +2 −2 pkgs/applications/version-management/gitlab/gitaly/default.nix
  23. +2 −2 pkgs/applications/version-management/gitlab/gitaly/gemset.nix
  24. +4 −6 pkgs/applications/version-management/gitlab/update.py
  25. +2 −12 pkgs/applications/video/openshot-qt/default.nix
  26. +2 −3 pkgs/applications/video/openshot-qt/libopenshot-audio.nix
  27. +2 −3 pkgs/applications/video/openshot-qt/libopenshot.nix
  28. +11 −8 pkgs/applications/video/wf-recorder/default.nix
  29. +6 −6 pkgs/applications/virtualization/nvidia-docker/libnvc-ldconfig-and-path-fixes.patch
  30. +5 −3 pkgs/applications/virtualization/nvidia-docker/libnvc.nix
  31. +30 −10 pkgs/build-support/emacs/setup-hook.sh
  32. +4 −4 pkgs/development/coq-modules/gappalib/default.nix
  33. +25 −0 pkgs/development/haskell-modules/configuration-common.nix
  34. +2 −2 pkgs/development/haskell-modules/configuration-hackage2nix.yaml
  35. +2 −0 pkgs/development/haskell-modules/configuration-nix.nix
  36. +49 −9 pkgs/development/haskell-modules/hackage-packages.nix
  37. +16 −3 pkgs/development/interpreters/python/sitecustomize.py
  38. +1 −1 pkgs/development/interpreters/python/wrapper.nix
  39. +8 −7 pkgs/development/libraries/boringssl/default.nix
  40. +4 −4 pkgs/development/libraries/libvorbis/default.nix
  41. +8 −4 pkgs/development/libraries/nss/{3_51.nix → 3_52.nix}
  42. +2 −2 pkgs/development/libraries/openldap/default.nix
  43. +5 −3 pkgs/development/libraries/p11-kit/default.nix
  44. +1 −1 pkgs/development/python-modules/tensorflow/1/default.nix
  45. +2 −2 pkgs/development/tools/packer/default.nix
  46. +2 −2 pkgs/development/tools/vagrant/default.nix
  47. +18 −19 pkgs/development/tools/vagrant/gemset.nix
  48. +14 −2 pkgs/games/steam/chrootenv.nix
  49. +538 −106 pkgs/games/steam/runtime-generated.nix
  50. +3 −3 pkgs/misc/cups/drivers/cnijfilter2/default.nix
  51. +2 −0 pkgs/os-specific/linux/broadcom-sta/default.nix
  52. +87 −0 pkgs/os-specific/linux/broadcom-sta/linux-5.6.patch
  53. +2 −2 pkgs/os-specific/linux/kernel/linux-4.14.nix
  54. +2 −2 pkgs/os-specific/linux/kernel/linux-4.19.nix
  55. +2 −2 pkgs/os-specific/linux/kernel/linux-4.4.nix
  56. +2 −2 pkgs/os-specific/linux/kernel/linux-4.9.nix
  57. +2 −2 pkgs/os-specific/linux/kernel/linux-5.4.nix
  58. +2 −2 pkgs/os-specific/linux/kernel/linux-5.6.nix
  59. +2 −2 pkgs/os-specific/linux/v4l2loopback/default.nix
  60. +2 −2 pkgs/os-specific/linux/wireguard/default.nix
  61. +6 −4 pkgs/servers/coturn/default.nix
  62. +2 −2 pkgs/servers/roundcube/default.nix
  63. +25 −8 pkgs/tools/admin/salt/default.nix
  64. +9 −1 pkgs/tools/archivers/p7zip/default.nix
  65. +2 −2 pkgs/tools/misc/clipman/default.nix
  66. +7 −7 pkgs/tools/misc/memtest86-efi/default.nix
  67. +2 −2 pkgs/tools/misc/youtube-dl/default.nix
  68. +3 −3 pkgs/tools/networking/bandwhich/default.nix
  69. +2 −11 pkgs/tools/networking/dnsmasq/default.nix
  70. +3 −3 pkgs/tools/security/keybase/default.nix
  71. +4 −4 pkgs/tools/security/keybase/gui.nix
  72. +1 −1 pkgs/tools/security/keybase/kbfs.nix
  73. +4 −1 pkgs/top-level/all-packages.nix
8 changes: 4 additions & 4 deletions nixos/modules/security/acme.nix
Original file line number Diff line number Diff line change
@@ -87,13 +87,13 @@ let
default = {};
example = literalExample ''
{
"example.org" = "/srv/http/nginx";
"example.org" = null;
"mydomain.org" = null;
}
'';
description = ''
A list of extra domain names, which are included in the one certificate to be issued, with their
own server roots if needed.
A list of extra domain names, which are included in the one certificate to be issued.
Setting a distinct server root is deprecated and not functional in 20.03+
'';
};

@@ -229,7 +229,7 @@ in
"example.com" = {
webroot = "/var/www/challenges/";
email = "foo@example.com";
extraDomains = { "www.example.com" = null; "foo.example.com" = "/var/www/foo/"; };
extraDomains = { "www.example.com" = null; "foo.example.com" = null; };
};
"bar.example.com" = {
webroot = "/var/www/challenges/";
247 changes: 202 additions & 45 deletions nixos/modules/security/acme.xml
Original file line number Diff line number Diff line change
@@ -6,92 +6,249 @@
<title>SSL/TLS Certificates with ACME</title>
<para>
NixOS supports automatic domain validation &amp; certificate retrieval and
renewal using the ACME protocol. This is currently only implemented by and
for Let's Encrypt. The alternative ACME client <literal>lego</literal> is
used under the hood.
renewal using the ACME protocol. Any provider can be used, but by default
NixOS uses Let's Encrypt. The alternative ACME client <literal>lego</literal>
is used under the hood.
</para>
<para>
Automatic cert validation and configuration for Apache and Nginx virtual
hosts is included in NixOS, however if you would like to generate a wildcard
cert or you are not using a web server you will have to configure DNS
based validation.
</para>
<section xml:id="module-security-acme-prerequisites">
<title>Prerequisites</title>

<para>
You need to have a running HTTP server for verification. The server must
have a webroot defined that can serve
To use the ACME module, you must accept the provider's terms of service
by setting <literal><xref linkend="opt-security.acme.acceptTerms" /></literal>
to <literal>true</literal>. The Let's Encrypt ToS can be found
<link xlink:href="https://letsencrypt.org/repository/">here</link>.
</para>

<para>
You must also set an email address to be used when creating accounts with
Let's Encrypt. You can set this for all certs with
<literal><xref linkend="opt-security.acme.email" /></literal>
and/or on a per-cert basis with
<literal><xref linkend="opt-security.acme.certs._name_.email" /></literal>.
This address is only used for registration and renewal reminders,
and cannot be used to administer the certificates in any way.
</para>

<para>
Alternatively, you can use a different ACME server by changing the
<literal><xref linkend="opt-security.acme.server" /></literal> option
to a provider of your choosing, or just change the server for one cert with
<literal><xref linkend="opt-security.acme.certs._name_.server" /></literal>.
</para>

<para>
You will need an HTTP server or DNS server for verification. For HTTP,
the server must have a webroot defined that can serve
<filename>.well-known/acme-challenge</filename>. This directory must be
writeable by the user that will run the ACME client.
writeable by the user that will run the ACME client. For DNS, you must
set up credentials with your provider/server for use with lego.
</para>
</section>
<section xml:id="module-security-acme-nginx">
<title>Using ACME certificates in Nginx</title>

<para>
For instance, this generic snippet could be used for Nginx:
NixOS supports fetching ACME certificates for you by setting
<literal><link linkend="opt-services.nginx.virtualHosts._name_.enableACME">enableACME</link>
= true;</literal> in a virtualHost config. We first create self-signed
placeholder certificates in place of the real ACME certs. The placeholder
certs are overwritten when the ACME certs arrive. For
<literal>foo.example.com</literal> the config would look like.
</para>

<programlisting>
http {
server {
server_name _;
listen 80;
listen [::]:80;

location /.well-known/acme-challenge {
root /var/www/challenges;
}
<xref linkend="opt-security.acme.acceptTerms" /> = true;
<xref linkend="opt-security.acme.email" /> = "admin+acme@example.com";
services.nginx = {
<link linkend="opt-services.nginx.enable">enable</link> = true;
<link linkend="opt-services.nginx.virtualHosts">virtualHosts</link> = {
"foo.example.com" = {
<link linkend="opt-services.nginx.virtualHosts._name_.forceSSL">forceSSL</link> = true;
<link linkend="opt-services.nginx.virtualHosts._name_.enableACME">enableACME</link> = true;
# All serverAliases will be added as <link linkend="opt-security.acme.certs._name_.extraDomains">extra domains</link> on the certificate.
<link linkend="opt-services.nginx.virtualHosts._name_.serverAliases">serverAliases</link> = [ "bar.example.com" ];
locations."/" = {
<link linkend="opt-services.nginx.virtualHosts._name_.locations._name_.root">root</link> = "/var/www";
};
};

location / {
return 301 https://$host$request_uri;
}
}
# We can also add a different vhost and reuse the same certificate
# but we have to append extraDomains manually.
<link linkend="opt-security.acme.certs._name_.extraDomains">security.acme.certs."foo.example.com".extraDomains."baz.example.com"</link> = null;
"baz.example.com" = {
<link linkend="opt-services.nginx.virtualHosts._name_.forceSSL">forceSSL</link> = true;
<link linkend="opt-services.nginx.virtualHosts._name_.useACMEHost">useACMEHost</link> = "foo.example.com";
locations."/" = {
<link linkend="opt-services.nginx.virtualHosts._name_.locations._name_.root">root</link> = "/var/www";
};
};
};
}
</programlisting>
</section>
<section xml:id="module-security-acme-httpd">
<title>Using ACME certificates in Apache/httpd</title>

<para>
Using ACME certificates with Apache virtual hosts is identical
to using them with Nginx. The attribute names are all the same, just replace
"nginx" with "httpd" where appropriate.
</para>
</section>
<section xml:id="module-security-acme-configuring">
<title>Configuring</title>
<title>Manual configuration of HTTP-01 validation</title>

<para>
To enable ACME certificate retrieval &amp; renewal for a certificate for
<literal>foo.example.com</literal>, add the following in your
<filename>configuration.nix</filename>:
First off you will need to set up a virtual host to serve the challenges.
This example uses a vhost called <literal>certs.example.com</literal>, with
the intent that you will generate certs for all your vhosts and redirect
everyone to HTTPS.
</para>

<programlisting>
<xref linkend="opt-security.acme.acceptTerms" /> = true;
<xref linkend="opt-security.acme.email" /> = "admin+acme@example.com";
services.nginx = {
<link linkend="opt-services.nginx.enable">enable</link> = true;
<link linkend="opt-services.nginx.virtualHosts">virtualHosts</link> = {
"acmechallenge.example.com" = {
# Catchall vhost, will redirect users to HTTPS for all vhosts
<link linkend="opt-services.nginx.virtualHosts._name_.serverAliases">serverAliases</link> = [ "*.example.com" ];
# /var/lib/acme/.challenges must be writable by the ACME user
# and readable by the Nginx user.
# By default, this is the case.
locations."/.well-known/acme-challenge" = {
<link linkend="opt-services.nginx.virtualHosts._name_.locations._name_.root">root</link> = "/var/lib/acme/.challenges";
};
locations."/" = {
<link linkend="opt-services.nginx.virtualHosts._name_.locations._name_.return">return</link> = "301 https://$host$request_uri";
};
};
};
}
# Alternative config for Apache
services.httpd = {
<link linkend="opt-services.httpd.enable">enable = true;</link>
<link linkend="opt-services.httpd.virtualHosts">virtualHosts</link> = {
"acmechallenge.example.com" = {
# Catchall vhost, will redirect users to HTTPS for all vhosts
<link linkend="opt-services.httpd.virtualHosts._name_.serverAliases">serverAliases</link> = [ "*.example.com" ];
# /var/lib/acme/.challenges must be writable by the ACME user and readable by the Apache user.
# By default, this is the case.
<link linkend="opt-services.httpd.virtualHosts._name_.documentRoot">documentRoot</link> = "/var/lib/acme/.challenges";
<link linkend="opt-services.httpd.virtualHosts._name_.extraConfig">extraConfig</link> = ''
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteCond %{REQUEST_URI} !^/\.well-known/acme-challenge [NC]
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301]
'';
};
};
}
</programlisting>

<para>
Now you need to configure ACME to generate a certificate.
</para>

<programlisting>
<xref linkend="opt-security.acme.certs"/>."foo.example.com" = {
<link linkend="opt-security.acme.certs._name_.webroot">webroot</link> = "/var/www/challenges";
<link linkend="opt-security.acme.certs._name_.webroot">webroot</link> = "/var/lib/acme/.challenges";
<link linkend="opt-security.acme.certs._name_.email">email</link> = "foo@example.com";
# Since we have a wildcard vhost to handle port 80,
# we can generate certs for anything!
# Just make sure your DNS resolves them.
<link linkend="opt-security.acme.certs._name_.extraDomains">extraDomains</link> = [ "mail.example.com" ];
};
</programlisting>
</para>

<para>
The private key <filename>key.pem</filename> and certificate
<filename>fullchain.pem</filename> will be put into
<filename>/var/lib/acme/foo.example.com</filename>.
</para>

<para>
Refer to <xref linkend="ch-options" /> for all available configuration
options for the <link linkend="opt-security.acme.certs">security.acme</link>
module.
</para>
</section>
<section xml:id="module-security-acme-nginx">
<title>Using ACME certificates in Nginx</title>
<section xml:id="module-security-acme-config-dns">
<title>Configuring ACME for DNS validation</title>

<para>
NixOS supports fetching ACME certificates for you by setting
<literal><link linkend="opt-services.nginx.virtualHosts._name_.enableACME">enableACME</link>
= true;</literal> in a virtualHost config. We first create self-signed
placeholder certificates in place of the real ACME certs. The placeholder
certs are overwritten when the ACME certs arrive. For
<literal>foo.example.com</literal> the config would look like.
This is useful if you want to generate a wildcard certificate, since
ACME servers will only hand out wildcard certs over DNS validation.
There a number of supported DNS providers and servers you can utilise,
see the <link xlink:href="https://go-acme.github.io/lego/dns/">lego docs</link>
for provider/server specific configuration values. For the sake of these
docs, we will provide a fully self-hosted example using bind.
</para>

<programlisting>
services.nginx = {
<link linkend="opt-services.nginx.enable">enable = true;</link>
<link linkend="opt-services.nginx.virtualHosts">virtualHosts</link> = {
"foo.example.com" = {
<link linkend="opt-services.nginx.virtualHosts._name_.forceSSL">forceSSL</link> = true;
<link linkend="opt-services.nginx.virtualHosts._name_.enableACME">enableACME</link> = true;
locations."/" = {
<link linkend="opt-services.nginx.virtualHosts._name_.locations._name_.root">root</link> = "/var/www";
};
};
};
services.bind = {
<link linkend="opt-services.bind.enable">enable</link> = true;
<link linkend="opt-services.bind.extraConfig">extraConfig</link> = ''
include "/var/lib/secrets/dnskeys.conf";
'';
<link linkend="opt-services.bind.zones">zones</link> = [
rec {
name = "example.com";
file = "/var/db/bind/${name}";
master = true;
extraConfig = "allow-update { key rfc2136key.example.com.; };";
}
];
}

# Now we can configure ACME
<xref linkend="opt-security.acme.acceptTerms" /> = true;
<xref linkend="opt-security.acme.email" /> = "admin+acme@example.com";
<xref linkend="opt-security.acme.certs" />."example.com" = {
<link linkend="opt-security.acme.certs._name_.domain">domain</link> = "*.example.com";
<link linkend="opt-security.acme.certs._name_.dnsProvider">dnsProvider</link> = "rfc2136";
<link linkend="opt-security.acme.certs._name_.credentialsFile">credentialsFile</link> = "/var/lib/secrets/certs.secret";
# We don't need to wait for propagation since this is a local DNS server
<link linkend="opt-security.acme.certs._name_.dnsPropagationCheck">dnsPropagationCheck</link> = false;
};
</programlisting>

<para>
The <filename>dnskeys.conf</filename> and <filename>certs.secret</filename>
must be kept secure and thus you should not keep their contents in your
Nix config. Instead, generate them one time with these commands:
</para>

<programlisting>
mkdir -p /var/lib/secrets
tsig-keygen rfc2136key.example.com &gt; /var/lib/secrets/dnskeys.conf
chown named:root /var/lib/secrets/dnskeys.conf
chmod 400 /var/lib/secrets/dnskeys.conf

# Copy the secret value from the dnskeys.conf, and put it in
# RFC2136_TSIG_SECRET below

cat &gt; /var/lib/secrets/certs.secret &lt;&lt; EOF
RFC2136_NAMESERVER='127.0.0.1:53'
RFC2136_TSIG_ALGORITHM='hmac-sha256.'
RFC2136_TSIG_KEY='rfc2136key.example.com'
RFC2136_TSIG_SECRET='your secret key'
EOF
chmod 400 /var/lib/secrets/certs.secret
</programlisting>

<para>
Now you're all set to generate certs! You should monitor the first invokation
by running <literal>systemctl start acme-example.com.service &amp;
journalctl -fu acme-example.com.service</literal> and watching its log output.
</para>
</section>
</chapter>
2 changes: 1 addition & 1 deletion nixos/modules/services/x11/desktop-managers/pantheon.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xml:id="chap-pantheon">
<title>Pantheon Destkop</title>
<title>Pantheon Desktop</title>
<para>
Pantheon is the desktop environment created for the elementary OS distribution. It is written from scratch in Vala, utilizing GNOME technologies with GTK 3 and Granite.
</para>
5 changes: 2 additions & 3 deletions pkgs/applications/misc/st/default.nix
Original file line number Diff line number Diff line change
@@ -13,9 +13,8 @@ stdenv.mkDerivation rec {

inherit patches;

prePatch = optionalString (conf != null) ''
cp ${writeText "config.def.h" conf} config.def.h
'';
configFile = optionalString (conf!=null) (writeText "config.def.h" conf);
postPatch = optionalString (conf!=null) "cp ${configFile} config.def.h";

nativeBuildInputs = [ pkgconfig ncurses ];
buildInputs = [ libX11 libXft ] ++ extraLibs;
Loading