From 34fcfc880bdc3c23c936e7b4d19bd0a93558d8f1 Mon Sep 17 00:00:00 2001 From: Erik Arvstedt Date: Tue, 15 Dec 2020 20:24:57 +0100 Subject: [PATCH 01/19] tests/containers-custom-pkgs: improve test - Fix name - Remove unneeded leftovers that were copied from containers-hosts.nix - Remove redundant 'start_all()' --- nixos/tests/containers-custom-pkgs.nix | 31 +++++++++----------------- 1 file changed, 11 insertions(+), 20 deletions(-) diff --git a/nixos/tests/containers-custom-pkgs.nix b/nixos/tests/containers-custom-pkgs.nix index 397a4a905e6d..47509892e52e 100644 --- a/nixos/tests/containers-custom-pkgs.nix +++ b/nixos/tests/containers-custom-pkgs.nix @@ -1,5 +1,3 @@ -# Test for NixOS' container support. - import ./make-test-python.nix ({ pkgs, lib, ...} : let customPkgs = pkgs // { @@ -9,34 +7,27 @@ import ./make-test-python.nix ({ pkgs, lib, ...} : let }; in { - name = "containers-hosts"; + name = "containers-custom-pkgs"; meta = with lib.maintainers; { maintainers = [ adisbladis ]; }; - machine = - { ... }: - { - virtualisation.memorySize = 256; - virtualisation.vlans = []; - - containers.simple = { - autoStart = true; - pkgs = customPkgs; - config = {pkgs, config, ... }: { - environment.systemPackages = [ - pkgs.hello - ]; - }; + machine = { ... }: { + containers.test = { + autoStart = true; + pkgs = customPkgs; + config = {pkgs, config, ... }: { + environment.systemPackages = [ + pkgs.hello + ]; }; - }; + }; testScript = '' - start_all() machine.wait_for_unit("default.target") machine.succeed( - "test $(nixos-container run simple -- readlink -f /run/current-system/sw/bin/hello) = ${customPkgs.hello}/bin/hello" + "test $(nixos-container run test -- readlink -f /run/current-system/sw/bin/hello) = ${customPkgs.hello}/bin/hello" ) ''; }) From 29385f0560ed3ed350f1af56b1ac3f827887ec56 Mon Sep 17 00:00:00 2001 From: Erik Arvstedt Date: Tue, 15 Dec 2020 20:24:58 +0100 Subject: [PATCH 02/19] nixos-containers: remove redundant eval-config args The values of these args are identical to the default values defined in `eval-config.nix`. Note especially that `lib` is not reevaluated. --- nixos/modules/virtualisation/nixos-containers.nix | 2 -- 1 file changed, 2 deletions(-) diff --git a/nixos/modules/virtualisation/nixos-containers.nix b/nixos/modules/virtualisation/nixos-containers.nix index 26398afb3cf5..df9031c7e9ec 100644 --- a/nixos/modules/virtualisation/nixos-containers.nix +++ b/nixos/modules/virtualisation/nixos-containers.nix @@ -476,8 +476,6 @@ in merge = loc: defs: (import (confPkgs.path + "/nixos/lib/eval-config.nix") { inherit system; pkgs = confPkgs; - baseModules = import (confPkgs.path + "/nixos/modules/module-list.nix"); - inherit (confPkgs) lib; modules = let extraConfig = { From 77c4fc2e89eca27e7ba559ed5b0f053a5ef122ce Mon Sep 17 00:00:00 2001 From: Erik Arvstedt Date: Tue, 15 Dec 2020 20:24:59 +0100 Subject: [PATCH 03/19] nixos-container: simplify 'pkgs' option type Set the default value directly instead of using a `null` proxy value. --- nixos/modules/virtualisation/nixos-containers.nix | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/nixos/modules/virtualisation/nixos-containers.nix b/nixos/modules/virtualisation/nixos-containers.nix index df9031c7e9ec..5949c54052c4 100644 --- a/nixos/modules/virtualisation/nixos-containers.nix +++ b/nixos/modules/virtualisation/nixos-containers.nix @@ -469,13 +469,11 @@ in A specification of the desired configuration of this container, as a NixOS module. ''; - type = let - confPkgs = if config.pkgs == null then pkgs else config.pkgs; - in lib.mkOptionType { + type = lib.mkOptionType { name = "Toplevel NixOS config"; - merge = loc: defs: (import (confPkgs.path + "/nixos/lib/eval-config.nix") { + merge = loc: defs: (import (config.pkgs.path + "/nixos/lib/eval-config.nix") { inherit system; - pkgs = confPkgs; + pkgs = config.pkgs; modules = let extraConfig = { @@ -525,9 +523,9 @@ in }; pkgs = mkOption { - type = types.nullOr types.attrs; - default = null; - example = literalExample "pkgs"; + type = types.attrs; + default = pkgs; + defaultText = "pkgs"; description = '' Customise which nixpkgs to use for this container. ''; From 9a283a038d3c028f8b067c6b2e56f2e38bd93192 Mon Sep 17 00:00:00 2001 From: Erik Arvstedt Date: Tue, 15 Dec 2020 20:25:00 +0100 Subject: [PATCH 04/19] nixos-container: fix `nixpkgs` container options being ignored Since the introduction of option `containers..pkgs`, the `nixpkgs.*` options (including `nixpkgs.pkgs`, `nixpkgs.config`, ...) were always ignored in container configs, which broke existing containers. This was due to `containers..pkgs` having two separate effects: (1) It sets the source for the modules that are used to evaluate the container. (2) It sets the `pkgs` arg (`_module.args.pkgs`) that is used inside the container modules. This happens even when the default value of `containers..pkgs` is unchanged, in which case the container `pkgs` arg is set to the pkgs of the host system. Previously, the `pkgs` arg was determined by the `containers..config.nixpkgs.*` options. This commit reverts the breaking change (2) while adding a backwards-compatible way to achieve (1). It removes option `pkgs` and adds option `nixpkgs` which implements (1). Existing users of `pkgs` are informed by an error message to use option `nixpkgs` or to achieve only (2) by setting option `containers..config.nixpkgs.pkgs`. --- .../virtualisation/nixos-containers.nix | 49 +++++++++++++------ nixos/tests/containers-custom-pkgs.nix | 35 ++++++------- 2 files changed, 53 insertions(+), 31 deletions(-) diff --git a/nixos/modules/virtualisation/nixos-containers.nix b/nixos/modules/virtualisation/nixos-containers.nix index 5949c54052c4..c721858225c9 100644 --- a/nixos/modules/virtualisation/nixos-containers.nix +++ b/nixos/modules/virtualisation/nixos-containers.nix @@ -463,7 +463,6 @@ in { config, options, name, ... }: { options = { - config = mkOption { description = '' A specification of the desired configuration of this @@ -471,9 +470,8 @@ in ''; type = lib.mkOptionType { name = "Toplevel NixOS config"; - merge = loc: defs: (import (config.pkgs.path + "/nixos/lib/eval-config.nix") { + merge = loc: defs: (import "${toString config.nixpkgs}/nixos/lib/eval-config.nix" { inherit system; - pkgs = config.pkgs; modules = let extraConfig = { @@ -522,12 +520,18 @@ in ''; }; - pkgs = mkOption { - type = types.attrs; - default = pkgs; - defaultText = "pkgs"; + nixpkgs = mkOption { + type = types.path; + default = pkgs.path; + defaultText = "pkgs.path"; description = '' - Customise which nixpkgs to use for this container. + A path to the nixpkgs that provide the modules, pkgs and lib for evaluating the container. + + To only change the pkgs argument used inside the container modules, + set the nixpkgs.* options in the container . + Setting config.nixpkgs.pkgs = pkgs speeds up the container evaluation + by reusing the system pkgs, but the nixpkgs.config option in the + container config is ignored in this case. ''; }; @@ -668,14 +672,31 @@ in ''; }; + # Removed option. See `checkAssertion` below for the accompanying error message. + pkgs = mkOption { visible = false; }; } // networkOptions; - config = mkMerge - [ - (mkIf options.config.isDefined { - path = config.config.system.build.toplevel; - }) - ]; + config = let + # Throw an error when removed option `pkgs` is used. + # Because this is a submodule we cannot use `mkRemovedOptionModule` or option `assertions`. + optionPath = "containers.${name}.pkgs"; + files = showFiles options.pkgs.files; + checkAssertion = if options.pkgs.isDefined then throw '' + The option definition `${optionPath}' in ${files} no longer has any effect; please remove it. + + Alternatively, you can use the following options: + - containers.${name}.nixpkgs + This sets the nixpkgs (and thereby the modules, pkgs and lib) that + are used for evaluating the container. + + - containers.${name}.config.nixpkgs.pkgs + This only sets the `pkgs` argument used inside the container modules. + '' + else null; + in { + path = builtins.seq checkAssertion + mkIf options.config.isDefined config.config.system.build.toplevel; + }; })); default = {}; diff --git a/nixos/tests/containers-custom-pkgs.nix b/nixos/tests/containers-custom-pkgs.nix index 47509892e52e..1412c32bfb5f 100644 --- a/nixos/tests/containers-custom-pkgs.nix +++ b/nixos/tests/containers-custom-pkgs.nix @@ -1,33 +1,34 @@ import ./make-test-python.nix ({ pkgs, lib, ...} : let - customPkgs = pkgs // { - hello = pkgs.hello.overrideAttrs(old: { - name = "custom-hello"; + customPkgs = pkgs.appendOverlays [ (self: super: { + hello = super.hello.overrideAttrs (old: { + name = "custom-hello"; }); - }; + }) ]; in { name = "containers-custom-pkgs"; meta = with lib.maintainers; { - maintainers = [ adisbladis ]; + maintainers = [ adisbladis earvstedt ]; }; - machine = { ... }: { + machine = { config, ... }: { + assertions = let + helloName = (builtins.head config.containers.test.config.system.extraDependencies).name; + in [ { + assertion = helloName == "custom-hello"; + message = "Unexpected value: ${helloName}"; + } ]; + containers.test = { autoStart = true; - pkgs = customPkgs; - config = {pkgs, config, ... }: { - environment.systemPackages = [ - pkgs.hello - ]; + config = { pkgs, config, ... }: { + nixpkgs.pkgs = customPkgs; + system.extraDependencies = [ pkgs.hello ]; }; }; }; - testScript = '' - machine.wait_for_unit("default.target") - machine.succeed( - "test $(nixos-container run test -- readlink -f /run/current-system/sw/bin/hello) = ${customPkgs.hello}/bin/hello" - ) - ''; + # This test only consists of evaluating the test machine + testScript = ""; }) From e2b7bdd08d2fccaa5f714d35b78930c6091eb7e1 Mon Sep 17 00:00:00 2001 From: Sascha Grunert Date: Thu, 4 Feb 2021 15:01:10 +0100 Subject: [PATCH 05/19] nixos/cri-o: add OCI seccomp bpf hook support We now set the hooks dir correctly if the OCI hook is enabled. CRI-O supports this specific hook from v1.20.0. Signed-off-by: Sascha Grunert --- nixos/modules/virtualisation/cri-o.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/nixos/modules/virtualisation/cri-o.nix b/nixos/modules/virtualisation/cri-o.nix index aa416e7990a8..8d352e36ef99 100644 --- a/nixos/modules/virtualisation/cri-o.nix +++ b/nixos/modules/virtualisation/cri-o.nix @@ -103,7 +103,10 @@ in cgroup_manager = "systemd" log_level = "${cfg.logLevel}" pinns_path = "${cfg.package}/bin/pinns" - hooks_dir = [] + hooks_dir = [ + ${lib.optionalString config.virtualisation.containers.ociSeccompBpfHook.enable + ''"${config.boot.kernelPackages.oci-seccomp-bpf-hook}",''} + ] ${optionalString (cfg.runtime != null) '' default_runtime = "${cfg.runtime}" From d6e9509ae416729cf23da36982dfc95efdd77e17 Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Fri, 5 Feb 2021 12:49:10 +0000 Subject: [PATCH 06/19] php73Packages.phpstan: 0.12.70 -> 0.12.71 --- pkgs/development/php-packages/phpstan/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/php-packages/phpstan/default.nix b/pkgs/development/php-packages/phpstan/default.nix index 74b44c21d047..1d6de2885620 100644 --- a/pkgs/development/php-packages/phpstan/default.nix +++ b/pkgs/development/php-packages/phpstan/default.nix @@ -1,14 +1,14 @@ { mkDerivation, fetchurl, pkgs, lib, php }: let pname = "phpstan"; - version = "0.12.70"; + version = "0.12.71"; in mkDerivation { inherit pname version; src = pkgs.fetchurl { url = "https://github.com/phpstan/phpstan/releases/download/${version}/phpstan.phar"; - sha256 = "sha256-bQvLGrDUh66lipmML1VwrdNKkI6NezBckdlOqnDe7Qk="; + sha256 = "sha256-VSA/37LTawwIL1qdyp35auml7we3xDdrZN21/V3BWlM="; }; phases = [ "installPhase" ]; From c67696b949560315566767f57a027fbb3593092a Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Fri, 5 Feb 2021 13:41:30 +0000 Subject: [PATCH 07/19] php73Extensions.redis: 5.3.2 -> 5.3.3 --- pkgs/development/php-packages/redis/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/php-packages/redis/default.nix b/pkgs/development/php-packages/redis/default.nix index a61ae1194ffb..fedc7a7ffde2 100644 --- a/pkgs/development/php-packages/redis/default.nix +++ b/pkgs/development/php-packages/redis/default.nix @@ -3,8 +3,8 @@ buildPecl { pname = "redis"; - version = "5.3.2"; - sha256 = "1cfsbxf3q3im0cmalgk76jpz581zr92z03c1viy93jxb53k2vsgl"; + version = "5.3.3"; + sha256 = "sha256-N3iRYeFkzVIjmjDJojjaYf7FyDlc2sOFtu2PDFD9kvA="; internalDeps = with php.extensions; [ session From 8f4f2f57e54155c65e32a956ae14d68e66d55c6e Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Fri, 5 Feb 2021 18:29:04 +0000 Subject: [PATCH 08/19] python37Packages.django_3: 3.1.5 -> 3.1.6 --- pkgs/development/python-modules/django/3.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/django/3.nix b/pkgs/development/python-modules/django/3.nix index 2444146e8374..7b447eb8d787 100644 --- a/pkgs/development/python-modules/django/3.nix +++ b/pkgs/development/python-modules/django/3.nix @@ -13,13 +13,13 @@ buildPythonPackage rec { pname = "Django"; - version = "3.1.5"; + version = "3.1.6"; disabled = pythonOlder "3.7"; src = fetchPypi { inherit pname version; - sha256 = "2d78425ba74c7a1a74b196058b261b9733a8570782f4e2828974777ccca7edf7"; + sha256 = "c6c0462b8b361f8691171af1fb87eceb4442da28477e12200c40420176206ba7"; }; patches = lib.optional withGdal From 32f98928a0f8ec7928e12898c1bf67543d5cb9b0 Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Fri, 5 Feb 2021 19:01:34 +0000 Subject: [PATCH 09/19] python37Packages.flask-paginate: 0.8.0 -> 0.8.1 --- pkgs/development/python-modules/flask-paginate/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/flask-paginate/default.nix b/pkgs/development/python-modules/flask-paginate/default.nix index 212e3a6fcc2b..214c89e1d4b2 100644 --- a/pkgs/development/python-modules/flask-paginate/default.nix +++ b/pkgs/development/python-modules/flask-paginate/default.nix @@ -2,11 +2,11 @@ buildPythonPackage rec { pname = "flask-paginate"; - version = "0.8.0"; + version = "0.8.1"; src = fetchPypi { inherit pname version; - sha256 = "60b2a696bf63d2bc1c90a5b1a861c280461732b88f079c267dc98021911a007b"; + sha256 = "31133c29c718aed95276425f7795d0a32b8d45a992ddd359c69600f22f869254"; }; propagatedBuildInputs = [ flask ]; From 1c7ef26e40b4886603df2656a506bb7d5aa849c9 Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Fri, 5 Feb 2021 22:31:38 +0000 Subject: [PATCH 10/19] python37Packages.casbin: 0.16.1 -> 0.16.2 --- pkgs/development/python-modules/casbin/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/casbin/default.nix b/pkgs/development/python-modules/casbin/default.nix index 2587772127b1..7e26181cf552 100644 --- a/pkgs/development/python-modules/casbin/default.nix +++ b/pkgs/development/python-modules/casbin/default.nix @@ -8,7 +8,7 @@ buildPythonPackage rec { pname = "casbin"; - version = "0.16.1"; + version = "0.16.2"; disabled = isPy27; @@ -16,7 +16,7 @@ buildPythonPackage rec { owner = pname; repo = "pycasbin"; rev = "v${version}"; - sha256 = "1bjrg0ig40rjk5x65x7ac9xsl332r0ypqgrqjdivb5dvplifnw36"; + sha256 = "0jan4xikyi1p92rsir8camc6ify81wnd9l57v1pgmjf5fgb5r2w8"; }; propagatedBuildInputs = [ From a0fa916147082a0cd65ba55a3a3fb2d9e9a854a9 Mon Sep 17 00:00:00 2001 From: Scriptkiddi Date: Fri, 5 Feb 2021 08:17:31 +0100 Subject: [PATCH 11/19] nixos/venus: Dropping module --- nixos/modules/module-list.nix | 1 - nixos/modules/programs/venus.nix | 173 ------------------------------- nixos/modules/rename.nix | 1 + 3 files changed, 1 insertion(+), 174 deletions(-) delete mode 100644 nixos/modules/programs/venus.nix diff --git a/nixos/modules/module-list.nix b/nixos/modules/module-list.nix index a5d68ce7fe0a..acd5ad9de2e7 100644 --- a/nixos/modules/module-list.nix +++ b/nixos/modules/module-list.nix @@ -177,7 +177,6 @@ ./programs/tsm-client.nix ./programs/udevil.nix ./programs/usbtop.nix - ./programs/venus.nix ./programs/vim.nix ./programs/wavemon.nix ./programs/waybar.nix diff --git a/nixos/modules/programs/venus.nix b/nixos/modules/programs/venus.nix deleted file mode 100644 index 58faf38777d0..000000000000 --- a/nixos/modules/programs/venus.nix +++ /dev/null @@ -1,173 +0,0 @@ -{ config, lib, pkgs, ... }: - -with lib; -let - cfg = config.services.venus; - - configFile = pkgs.writeText "venus.ini" - '' - [Planet] - name = ${cfg.name} - link = ${cfg.link} - owner_name = ${cfg.ownerName} - owner_email = ${cfg.ownerEmail} - output_theme = ${cfg.cacheDirectory}/theme - output_dir = ${cfg.outputDirectory} - cache_directory = ${cfg.cacheDirectory} - items_per_page = ${toString cfg.itemsPerPage} - ${(concatStringsSep "\n\n" - (map ({ name, feedUrl, homepageUrl }: - '' - [${feedUrl}] - name = ${name} - link = ${homepageUrl} - '') cfg.feeds))} - ''; - -in -{ - - options = { - services.venus = { - enable = mkOption { - default = false; - type = types.bool; - description = '' - Planet Venus is an awesome ‘river of news’ feed reader. It downloads - news feeds published by web sites and aggregates their content - together into a single combined feed, latest news first. - ''; - }; - - dates = mkOption { - default = "*:0/15"; - type = types.str; - description = '' - Specification (in the format described by - systemd.time - 7) of the time at - which the Venus will collect feeds. - ''; - }; - - user = mkOption { - default = "root"; - type = types.str; - description = '' - User for running venus script. - ''; - }; - - group = mkOption { - default = "root"; - type = types.str; - description = '' - Group for running venus script. - ''; - }; - - name = mkOption { - default = "NixOS Planet"; - type = types.str; - description = '' - Your planet's name. - ''; - }; - - link = mkOption { - default = "https://planet.nixos.org"; - type = types.str; - description = '' - Link to the main page. - ''; - }; - - ownerName = mkOption { - default = "Rok Garbas"; - type = types.str; - description = '' - Your name. - ''; - }; - - ownerEmail = mkOption { - default = "some@example.com"; - type = types.str; - description = '' - Your e-mail address. - ''; - }; - - outputTheme = mkOption { - default = "${pkgs.venus}/themes/classic_fancy"; - type = types.path; - description = '' - Directory containing a config.ini file which is merged with this one. - This is typically used to specify templating and bill of material - information. - ''; - }; - - outputDirectory = mkOption { - type = types.path; - description = '' - Directory to place output files. - ''; - }; - - cacheDirectory = mkOption { - default = "/var/cache/venus"; - type = types.path; - description = '' - Where cached feeds are stored. - ''; - }; - - itemsPerPage = mkOption { - default = 15; - type = types.int; - description = '' - How many items to put on each page. - ''; - }; - - feeds = mkOption { - default = []; - example = [ - { - name = "Rok Garbas"; - feedUrl= "http://url/to/rss/feed.xml"; - homepageUrl = "http://garbas.si"; - } - ]; - description = '' - List of feeds. - ''; - }; - - }; - }; - - config = mkIf cfg.enable { - - system.activationScripts.venus = - '' - mkdir -p ${cfg.outputDirectory} - chown ${cfg.user}:${cfg.group} ${cfg.outputDirectory} -R - rm -rf ${cfg.cacheDirectory}/theme - mkdir -p ${cfg.cacheDirectory}/theme - cp -R ${cfg.outputTheme}/* ${cfg.cacheDirectory}/theme - chown ${cfg.user}:${cfg.group} ${cfg.cacheDirectory} -R - ''; - - systemd.services.venus = - { description = "Planet Venus Feed Reader"; - path = [ pkgs.venus ]; - script = "exec venus-planet ${configFile}"; - serviceConfig.User = "${cfg.user}"; - serviceConfig.Group = "${cfg.group}"; - startAt = cfg.dates; - }; - - }; -} diff --git a/nixos/modules/rename.nix b/nixos/modules/rename.nix index c6f705bb2d6c..1dd8b48d76b5 100644 --- a/nixos/modules/rename.nix +++ b/nixos/modules/rename.nix @@ -70,6 +70,7 @@ with lib; '') (mkRemovedOptionModule [ "services" "seeks" ] "") + (mkRemovedOptionModule [ "services" "venus" ] "The corresponding package was removed from nixpkgs.") # Do NOT add any option renames here, see top of the file ]; From b1a729198ccbf9007fb925871a1c45fd671866eb Mon Sep 17 00:00:00 2001 From: Scriptkiddi Date: Fri, 5 Feb 2021 08:17:52 +0100 Subject: [PATCH 12/19] nixos/venus: Dropping package --- pkgs/tools/misc/venus/default.nix | 53 ------------------------------- pkgs/top-level/aliases.nix | 1 + pkgs/top-level/all-packages.nix | 4 --- 3 files changed, 1 insertion(+), 57 deletions(-) delete mode 100644 pkgs/tools/misc/venus/default.nix diff --git a/pkgs/tools/misc/venus/default.nix b/pkgs/tools/misc/venus/default.nix deleted file mode 100644 index 28c4508525ec..000000000000 --- a/pkgs/tools/misc/venus/default.nix +++ /dev/null @@ -1,53 +0,0 @@ -{ lib, stdenv, fetchFromGitHub, python, pythonPackages, libxslt, libxml2, makeWrapper }: - -stdenv.mkDerivation rec { - pname = "venus"; - version = "unstable-2011-02-18"; - - src = fetchFromGitHub { - owner = "rubys"; - repo = "venus"; - rev = "9de21094a8cf565bdfcf75688e121a5ad1f5397b"; - sha256 = "10yyx4jaxxbwhica12aiw119aywghcr7b24gs9lrmafpa6xd3an2"; - }; - - preConfigure = '' - substituteInPlace tests/test_spider.py \ - --replace "urllib.urlopen('http://127.0.0.1:%d/' % _PORT).read()" "" \ - --replace "[200,200,200,200,404]" "[200,200,200,404]" - substituteInPlace planet.py \ - --replace "#!/usr/bin/env python" "#!${python}/bin/python" - substituteInPlace tests/test_apply.py \ - --replace "'xsltproc" "'${libxslt.bin}/bin/xsltproc" - substituteInPlace planet/shell/xslt.py \ - --replace "'xsltproc" "'${libxslt.bin}/bin/xsltproc" - ''; - - doCheck = true; - checkPhase = "python runtests.py"; - - buildInputs = [ python libxslt - libxml2 pythonPackages.genshi pythonPackages.lxml makeWrapper ]; - - installPhase = '' - mkdir -p $out/bin - cp -R ./* $out/ - ln -s $out/planet.py $out/bin/venus-planet - wrapProgram $out/planet.py \ - --prefix PYTHONPATH : $PYTHONPATH:${pythonPackages.lxml}/lib/${python.libPrefix}/site-packages:${pythonPackages.genshi}/lib/${python.libPrefix}/site-packages - python runtests.py - ''; - - meta = { - description = "News feed reader"; - longDescription = '' - Planet Venus is an awesome ‘river of news’ feed reader. It downloads news - feeds published by web sites and aggregates their content together into a - single combined feed, latest news first. - ''; - homepage = "http://intertwingly.net/code/venus/docs/index.html"; - license = lib.licenses.psfl; - platforms = lib.platforms.all; - maintainers = []; - }; -} diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index bb2fb36bb5b3..fbd30aea40a0 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -717,6 +717,7 @@ mapAliases ({ v8_3_16_14 = throw "v8_3_16_14 was removed in 2019-11-01: no longer referenced by other packages"; valadoc = throw "valadoc was deprecated on 2019-10-10: valadoc was merged into vala 0.38"; vamp = { vampSDK = vamp-plugin-sdk; }; # added 2020-03-26 + venus = throw "venus has been removed from nixpkgs, as it's unmaintained"; # added 2021-02-05 vdirsyncerStable = vdirsyncer; # added 2020-11-08, see https://github.com/NixOS/nixpkgs/issues/103026#issuecomment-723428168 vimbWrapper = vimb; # added 2015-01 vimprobable2 = throw "vimprobable2 has been removed from nixpkgs. It relied on webkitgtk24x that has been removed."; # added 2019-12-05 diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index a65364271dad..4839d14e006d 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8972,10 +8972,6 @@ in hitch = callPackage ../servers/hitch { }; - venus = callPackage ../tools/misc/venus { - python = python27; - }; - veracrypt = callPackage ../applications/misc/veracrypt { wxGTK = wxGTK30; }; From bce3b161c0959dc5f5833bbbc19a9a5df9376515 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Sat, 6 Feb 2021 09:19:46 +0100 Subject: [PATCH 13/19] nebula: fix internal build version --- pkgs/tools/networking/nebula/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/tools/networking/nebula/default.nix b/pkgs/tools/networking/nebula/default.nix index 61f0a00a9b81..06684016abcf 100644 --- a/pkgs/tools/networking/nebula/default.nix +++ b/pkgs/tools/networking/nebula/default.nix @@ -17,7 +17,7 @@ buildGoModule rec { subPackages = [ "cmd/nebula" "cmd/nebula-cert" ]; - buildFlagsArray = [ "-ldflags='-X main.Build=${version}'" ]; + buildFlagsArray = [ "-ldflags=" "-X main.Build=${version}" ]; meta = with lib; { description = "A scalable overlay networking tool with a focus on performance, simplicity and security"; From 8c0e0ef058abcd28ffbb1a1959ff8db785189a76 Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Sat, 6 Feb 2021 09:28:30 +0000 Subject: [PATCH 14/19] cni-plugins: 0.9.0 -> 0.9.1 --- pkgs/applications/networking/cluster/cni/plugins.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/networking/cluster/cni/plugins.nix b/pkgs/applications/networking/cluster/cni/plugins.nix index e01842205045..8fc667e3391c 100644 --- a/pkgs/applications/networking/cluster/cni/plugins.nix +++ b/pkgs/applications/networking/cluster/cni/plugins.nix @@ -2,13 +2,13 @@ buildGoModule rec { pname = "cni-plugins"; - version = "0.9.0"; + version = "0.9.1"; src = fetchFromGitHub { owner = "containernetworking"; repo = "plugins"; rev = "v${version}"; - sha256 = "1nkaspz96yglq1fr8a3xr39qmbs98pk7qpqav3cfd82qwbq7vs06"; + sha256 = "sha256-n+OtFXgFmW0xsGEtC6ua0qjdsJSbEjn08mAl5Z51Kp8="; }; vendorSha256 = null; From c8e7fd0fb3dc2e8486db9de4363b37bc0c20071f Mon Sep 17 00:00:00 2001 From: "R. RyanTM" Date: Sat, 6 Feb 2021 10:08:19 +0000 Subject: [PATCH 15/19] delta: 0.5.1 -> 0.6.0 --- .../version-management/git-and-tools/delta/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/version-management/git-and-tools/delta/default.nix b/pkgs/applications/version-management/git-and-tools/delta/default.nix index 465de2d1d2be..4b7785374694 100644 --- a/pkgs/applications/version-management/git-and-tools/delta/default.nix +++ b/pkgs/applications/version-management/git-and-tools/delta/default.nix @@ -9,16 +9,16 @@ rustPlatform.buildRustPackage rec { pname = "delta"; - version = "0.5.1"; + version = "0.6.0"; src = fetchFromGitHub { owner = "dandavison"; repo = pname; rev = version; - sha256 = "17cmwkha25hwsvnjcp388zd9kwacfq7adjp0sjw59y0vyr1maf22"; + sha256 = "sha256-cEVYU7vMgVxVIKztL6LHcvQjrNRRMrB5XMP/7gPCr5A="; }; - cargoSha256 = "1bji818cmkl0286a4qcnfiwibnqd5q5fvzmzgk5cabrdwaag2ia5"; + cargoSha256 = "sha256-iD3Cr1vo0FNyWvAN5m6ND+8sGyekgbkYmIxGTJkPEYE="; nativeBuildInputs = [ installShellFiles ]; From 9afb001819d70dab01bca02a3681bea36b59d1cb Mon Sep 17 00:00:00 2001 From: Antonio Nuno Monteiro Date: Wed, 3 Feb 2021 11:45:18 -0800 Subject: [PATCH 16/19] ocamlPackages.ssl: 0.5.9 -> 0.5.10 --- pkgs/development/ocaml-modules/lwt_ssl/default.nix | 1 + pkgs/development/ocaml-modules/ssl/default.nix | 12 ++++++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/pkgs/development/ocaml-modules/lwt_ssl/default.nix b/pkgs/development/ocaml-modules/lwt_ssl/default.nix index e74a743e6b18..173094aacb84 100644 --- a/pkgs/development/ocaml-modules/lwt_ssl/default.nix +++ b/pkgs/development/ocaml-modules/lwt_ssl/default.nix @@ -5,6 +5,7 @@ buildDunePackage rec { version = "1.1.3"; minimumOCamlVersion = "4.02"; + useDune2 = true; src = fetchzip { url = "https://github.com/aantron/${pname}/archive/${version}.tar.gz"; diff --git a/pkgs/development/ocaml-modules/ssl/default.nix b/pkgs/development/ocaml-modules/ssl/default.nix index 9a574a0457a5..1f4fd7b85805 100644 --- a/pkgs/development/ocaml-modules/ssl/default.nix +++ b/pkgs/development/ocaml-modules/ssl/default.nix @@ -1,17 +1,20 @@ -{ lib, buildDunePackage, fetchFromGitHub, pkg-config, openssl }: +{ lib, buildDunePackage, fetchFromGitHub, pkg-config, openssl +, dune-configurator }: buildDunePackage rec { pname = "ssl"; - version = "0.5.9"; + version = "0.5.10"; src = fetchFromGitHub { owner = "savonet"; repo = "ocaml-ssl"; - rev = version; - sha256 = "04h02rvzrwp886n5hsx84rnc9b150iggy38g5v1x1rwz3pkdnmf0"; + rev = "v${version}"; + sha256 = "1rszqiqayh67xlwd5411k8vib47x9kapdr037z1majd2c14z3kcb"; }; + useDune2 = true; nativeBuildInputs = [ pkg-config ]; + buildInputs = [ dune-configurator ]; propagatedBuildInputs = [openssl]; meta = { @@ -20,6 +23,7 @@ buildDunePackage rec { license = "LGPL+link exception"; maintainers = [ lib.maintainers.maggesi + lib.maintainers.anmonteiro ]; }; } From df9dac5e7754d38ee135d960d0fd5cfb86f3fc45 Mon Sep 17 00:00:00 2001 From: Michael Weiss Date: Sat, 6 Feb 2021 11:52:09 +0100 Subject: [PATCH 17/19] fuse3: 3.10.1 -> 3.10.2 (#112016) --- pkgs/os-specific/linux/fuse/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/os-specific/linux/fuse/default.nix b/pkgs/os-specific/linux/fuse/default.nix index 0ed6f54a1dcc..02c46b9ba772 100644 --- a/pkgs/os-specific/linux/fuse/default.nix +++ b/pkgs/os-specific/linux/fuse/default.nix @@ -11,7 +11,7 @@ in { }; fuse_3 = mkFuse { - version = "3.10.1"; - sha256Hash = "0bb22mac8m0z6qp0s6g4r0x4aj6gc19pfyqr6sdy4hkpwxicgmaf"; + version = "3.10.2"; + sha256Hash = "0m44hhk6jxkgkvk2jsjcwa3pqgzzqnpm606n3n8wn1ldypkvpsps"; }; } From 576464c74dc02d6ebb286f2a9f4b82d64d451ed1 Mon Sep 17 00:00:00 2001 From: Michael Weiss Date: Fri, 5 Feb 2021 14:29:47 +0100 Subject: [PATCH 18/19] chromium: Remove our old overrides for VA-API and Ozone These gn arguments aren't required anymore as they're now equal to the current defaults. --- .../networking/browsers/chromium/common.nix | 20 +++++-------------- 1 file changed, 5 insertions(+), 15 deletions(-) diff --git a/pkgs/applications/networking/browsers/chromium/common.nix b/pkgs/applications/networking/browsers/chromium/common.nix index d25dd2a78301..d93fc5ceb405 100644 --- a/pkgs/applications/networking/browsers/chromium/common.nix +++ b/pkgs/applications/networking/browsers/chromium/common.nix @@ -19,13 +19,12 @@ , jre8 , pipewire_0_2 , libva +, libdrm, wayland, mesa, libxkbcommon # Ozone # optional dependencies , libgcrypt ? null # gnomeSupport || cupsSupport -, libdrm ? null, wayland ? null, mesa ? null, libxkbcommon ? null # useOzone # package customization -, useOzone ? true , gnomeSupport ? false, gnome ? null , gnomeKeyringSupport ? false, libgnome-keyring3 ? null , proprietaryCodecs ? true @@ -143,11 +142,11 @@ let jre pipewire_0_2 libva + libdrm wayland mesa.drivers libxkbcommon ] ++ optional gnomeKeyringSupport libgnome-keyring3 ++ optionals gnomeSupport [ gnome.GConf libgcrypt ] ++ optionals cupsSupport [ libgcrypt cups ] - ++ optional pulseSupport libpulseaudio - ++ optionals useOzone [ libdrm wayland mesa.drivers libxkbcommon ]; + ++ optional pulseSupport libpulseaudio; patches = [ ./patches/no-build-timestamps.patch # Optional patch to use SOURCE_DATE_EPOCH in compute_build_timestamp.py (should be upstreamed) @@ -226,11 +225,11 @@ let ''; gnFlags = mkGnFlags ({ + is_official_build = true; custom_toolchain = "//build/toolchain/linux/unbundle:default"; host_toolchain = "//build/toolchain/linux/unbundle:default"; - is_official_build = true; + system_wayland_scanner_path = "${wayland}/bin/wayland-scanner"; - use_vaapi = !stdenv.isAarch64; # TODO: Remove once M88 is released use_sysroot = false; use_gnome_keyring = gnomeKeyringSupport; use_gio = gnomeSupport; @@ -266,15 +265,6 @@ let } // optionalAttrs pulseSupport { use_pulseaudio = true; link_pulseaudio = true; - } // optionalAttrs useOzone { - use_ozone = true; - use_xkbcommon = true; - use_glib = true; - use_gtk = true; - use_system_libwayland = true; - use_system_minigbm = true; - use_system_libdrm = true; - system_wayland_scanner_path = "${wayland}/bin/wayland-scanner"; } // optionalAttrs (chromiumVersionAtLeast "89") { # Disable PGO (defaults to 2 since M89) because it fails without additional changes: # error: Could not read profile ../../chrome/build/pgo_profiles/chrome-linux-master-1610647094-405a32bcf15e5a84949640f99f84a5b9f61e2f2e.profdata: Unsupported instrumentation profile format version From 671fd3a3c13383cc1d7805e2b7854b5226205d07 Mon Sep 17 00:00:00 2001 From: Orivej Desh Date: Sat, 6 Feb 2021 11:38:10 +0000 Subject: [PATCH 19/19] ht: fix build with gcc10 It builds with -Wall and fails on -Wnarrowing. --- pkgs/applications/editors/ht/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkgs/applications/editors/ht/default.nix b/pkgs/applications/editors/ht/default.nix index 096b69a5e82a..2f1ea40359d5 100644 --- a/pkgs/applications/editors/ht/default.nix +++ b/pkgs/applications/editors/ht/default.nix @@ -17,6 +17,8 @@ stdenv.mkDerivation rec { patches = [ ./gcc7.patch ]; + NIX_CFLAGS_COMPILE = [ "-Wno-narrowing" ]; + meta = with lib; { description = "File editor/viewer/analyzer for executables"; homepage = "http://hte.sourceforge.net";