forked from mirrors/nixpkgs
Merge staging-next into staging
This commit is contained in:
commit
fbd67854c6
|
@ -1292,7 +1292,7 @@ Existing 3rd party modules that provided similar functionality, like <literal>pu
|
|||
<literal>systemd-shutdown</literal> is now properly linked on
|
||||
shutdown to unmount all filesystems and device mapper devices
|
||||
cleanly. This can be disabled using
|
||||
<literal>boot.systemd.shutdown.enable</literal>.
|
||||
<literal>systemd.shutdownRamfs.enable</literal>.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
|
|
|
@ -513,7 +513,7 @@ In addition to numerous new and upgraded packages, this release has the followin
|
|||
|
||||
- `systemd-nspawn@.service` settings have been reverted to the default systemd behaviour. User namespaces are now activated by default. If you want to keep running nspawn containers without user namespaces you need to set `systemd.nspawn.<name>.execConfig.PrivateUsers = false`
|
||||
|
||||
- `systemd-shutdown` is now properly linked on shutdown to unmount all filesystems and device mapper devices cleanly. This can be disabled using `boot.systemd.shutdown.enable`.
|
||||
- `systemd-shutdown` is now properly linked on shutdown to unmount all filesystems and device mapper devices cleanly. This can be disabled using `systemd.shutdownRamfs.enable`.
|
||||
|
||||
- The Tor SOCKS proxy is now actually disabled if `services.tor.client.enable` is set to `false` (the default). If you are using this functionality but didn't change the setting or set it to `false`, you now need to set it to `true`.
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ lib, systemdUtils }:
|
||||
{ lib, systemdUtils, pkgs }:
|
||||
|
||||
with systemdUtils.lib;
|
||||
with systemdUtils.unitOptions;
|
||||
|
@ -34,4 +34,36 @@ rec {
|
|||
|
||||
automounts = with types; listOf (submodule [ stage2AutomountOptions unitConfig automountConfig ]);
|
||||
initrdAutomounts = with types; attrsOf (submodule [ stage1AutomountOptions unitConfig automountConfig ]);
|
||||
|
||||
initrdContents = types.attrsOf (types.submodule ({ config, options, name, ... }: {
|
||||
options = {
|
||||
enable = mkEnableOption "copying of this file and symlinking it" // { default = true; };
|
||||
|
||||
target = mkOption {
|
||||
type = types.path;
|
||||
description = ''
|
||||
Path of the symlink.
|
||||
'';
|
||||
default = name;
|
||||
};
|
||||
|
||||
text = mkOption {
|
||||
default = null;
|
||||
type = types.nullOr types.lines;
|
||||
description = "Text of the file.";
|
||||
};
|
||||
|
||||
source = mkOption {
|
||||
type = types.path;
|
||||
description = "Path of the source file.";
|
||||
};
|
||||
};
|
||||
|
||||
config = {
|
||||
source = mkIf (config.text != null) (
|
||||
let name' = "initrd-" + baseNameOf name;
|
||||
in mkDerivedConfig options.text (pkgs.writeText name')
|
||||
);
|
||||
};
|
||||
}));
|
||||
}
|
||||
|
|
|
@ -213,6 +213,6 @@ rec {
|
|||
systemdUtils = {
|
||||
lib = import ./systemd-lib.nix { inherit lib config pkgs; };
|
||||
unitOptions = import ./systemd-unit-options.nix { inherit lib systemdUtils; };
|
||||
types = import ./systemd-types.nix { inherit lib systemdUtils; };
|
||||
types = import ./systemd-types.nix { inherit lib systemdUtils pkgs; };
|
||||
};
|
||||
}
|
||||
|
|
|
@ -155,37 +155,7 @@ in {
|
|||
'';
|
||||
visible = false;
|
||||
default = {};
|
||||
type = types.attrsOf (types.submodule ({ config, options, name, ... }: {
|
||||
options = {
|
||||
enable = mkEnableOption "copying of this file to initrd and symlinking it" // { default = true; };
|
||||
|
||||
target = mkOption {
|
||||
type = types.path;
|
||||
description = ''
|
||||
Path of the symlink.
|
||||
'';
|
||||
default = name;
|
||||
};
|
||||
|
||||
text = mkOption {
|
||||
default = null;
|
||||
type = types.nullOr types.lines;
|
||||
description = "Text of the file.";
|
||||
};
|
||||
|
||||
source = mkOption {
|
||||
type = types.path;
|
||||
description = "Path of the source file.";
|
||||
};
|
||||
};
|
||||
|
||||
config = {
|
||||
source = mkIf (config.text != null) (
|
||||
let name' = "initrd-" + baseNameOf name;
|
||||
in mkDerivedConfig options.text (pkgs.writeText name')
|
||||
);
|
||||
};
|
||||
}));
|
||||
type = utils.systemdUtils.types.initrdContents;
|
||||
};
|
||||
|
||||
storePaths = mkOption {
|
||||
|
|
|
@ -1,31 +1,57 @@
|
|||
{ config, lib, ... }: let
|
||||
{ config, lib, utils, pkgs, ... }: let
|
||||
|
||||
cfg = config.boot.systemd.shutdown;
|
||||
cfg = config.systemd.shutdownRamfs;
|
||||
|
||||
ramfsContents = let
|
||||
storePaths = map (p: "${p}\n") cfg.storePaths;
|
||||
contents = lib.mapAttrsToList (_: v: "${v.source}\n${v.target}") (lib.filterAttrs (_: v: v.enable) cfg.contents);
|
||||
in pkgs.writeText "shutdown-ramfs-contents" (lib.concatStringsSep "\n" (storePaths ++ contents));
|
||||
|
||||
in {
|
||||
options.boot.systemd.shutdown = {
|
||||
options.systemd.shutdownRamfs = {
|
||||
enable = lib.mkEnableOption "pivoting back to an initramfs for shutdown" // { default = true; };
|
||||
contents = lib.mkOption {
|
||||
description = "Set of files that have to be linked into the shutdown ramfs";
|
||||
example = lib.literalExpression ''
|
||||
{
|
||||
"/lib/systemd/system-shutdown/zpool-sync-shutdown".source = writeShellScript "zpool" "exec ''${zfs}/bin/zpool sync"
|
||||
}
|
||||
'';
|
||||
type = utils.systemdUtils.types.initrdContents;
|
||||
};
|
||||
|
||||
storePaths = lib.mkOption {
|
||||
description = ''
|
||||
Store paths to copy into the shutdown ramfs as well.
|
||||
'';
|
||||
type = lib.types.listOf lib.types.singleLineStr;
|
||||
default = [];
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
systemd.shutdownRamfs.contents."/shutdown".source = "${config.systemd.package}/lib/systemd/systemd-shutdown";
|
||||
systemd.shutdownRamfs.storePaths = [pkgs.runtimeShell "${pkgs.coreutils}/bin"];
|
||||
|
||||
systemd.services.generate-shutdown-ramfs = {
|
||||
description = "Generate shutdown ramfs";
|
||||
wantedBy = [ "shutdown.target" ];
|
||||
before = [ "shutdown.target" ];
|
||||
unitConfig = {
|
||||
DefaultDependencies = false;
|
||||
ConditionFileIsExecutable = [
|
||||
"!/run/initramfs/shutdown"
|
||||
"/run/current-system/systemd/lib/systemd/systemd-shutdown"
|
||||
];
|
||||
};
|
||||
|
||||
path = [pkgs.util-linux pkgs.makeInitrdNGTool pkgs.glibc pkgs.patchelf];
|
||||
serviceConfig.Type = "oneshot";
|
||||
script = ''
|
||||
mkdir -p /run/initramfs
|
||||
if ! mountpoint -q /run/initramfs; then
|
||||
mount -t tmpfs tmpfs /run/initramfs
|
||||
fi
|
||||
cp /run/current-system/systemd/lib/systemd/systemd-shutdown /run/initramfs/shutdown
|
||||
make-initrd-ng ${ramfsContents} /run/initramfs
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
|
|
@ -466,6 +466,11 @@ in
|
|||
'') rootPools));
|
||||
};
|
||||
|
||||
systemd.shutdownRamfs.contents."/etc/systemd/system-shutdown/zpool".source = pkgs.writeShellScript "zpool-sync-shutdown" ''
|
||||
exec ${cfgZfs.package}/bin/zpool sync
|
||||
'';
|
||||
systemd.shutdownRamfs.storePaths = ["${cfgZfs.package}/bin/zpool"];
|
||||
|
||||
# TODO FIXME See https://github.com/NixOS/nixpkgs/pull/99386#issuecomment-798813567. To not break people's bootloader and as probably not everybody would read release notes that thoroughly add inSystem.
|
||||
boot.loader.grub = mkIf (inInitrd || inSystem) {
|
||||
zfsSupport = true;
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
import ./make-test-python.nix ({ pkgs, systemdStage1 ? false, ...} : {
|
||||
import ./make-test-python.nix ({ pkgs, systemdStage1 ? false, ...} : let
|
||||
msg = "Shutting down NixOS";
|
||||
in {
|
||||
name = "systemd-shutdown";
|
||||
meta = with pkgs.lib.maintainers; {
|
||||
maintainers = [ das_j ];
|
||||
|
@ -6,7 +8,9 @@ import ./make-test-python.nix ({ pkgs, systemdStage1 ? false, ...} : {
|
|||
|
||||
nodes.machine = {
|
||||
imports = [ ../modules/profiles/minimal.nix ];
|
||||
boot.initrd.systemd.enable = systemdStage1;
|
||||
systemd.shutdownRamfs.contents."/etc/systemd/system-shutdown/shutdown-message".source = pkgs.writeShellScript "shutdown-message" ''
|
||||
echo "${msg}"
|
||||
'';
|
||||
};
|
||||
|
||||
testScript = ''
|
||||
|
@ -14,7 +18,8 @@ import ./make-test-python.nix ({ pkgs, systemdStage1 ? false, ...} : {
|
|||
# .shutdown() would wait for the machine to power off
|
||||
machine.succeed("systemctl poweroff")
|
||||
# Message printed by systemd-shutdown
|
||||
machine.wait_for_console_text("All filesystems, swaps, loop devices, MD devices and DM devices detached.")
|
||||
machine.wait_for_console_text("Unmounting '/oldroot'")
|
||||
machine.wait_for_console_text("${msg}")
|
||||
# Don't try to sync filesystems
|
||||
machine.booted = False
|
||||
'';
|
||||
|
|
|
@ -174,6 +174,7 @@ let
|
|||
};
|
||||
disabledTestPaths = [
|
||||
"t/unit/backends/test_mongodb.py"
|
||||
"t/unit/backends/test_cassandra.py"
|
||||
];
|
||||
});
|
||||
}
|
||||
|
@ -254,6 +255,24 @@ let
|
|||
}
|
||||
)
|
||||
|
||||
(
|
||||
self: super: {
|
||||
flask-restful = super.flask-restful.overridePythonAttrs (oldAttrs: rec {
|
||||
# remove werkzeug patch
|
||||
patches = [];
|
||||
});
|
||||
}
|
||||
)
|
||||
|
||||
(
|
||||
self: super: {
|
||||
trytond = super.trytond.overridePythonAttrs (oldAttrs: rec {
|
||||
# remove werkzeug patch
|
||||
patches = [];
|
||||
});
|
||||
}
|
||||
)
|
||||
|
||||
# Built-in dependency
|
||||
(
|
||||
self: super: {
|
||||
|
@ -406,6 +425,7 @@ let
|
|||
"watchdog"
|
||||
"wrapt"
|
||||
"zeroconf"
|
||||
"Flask-Login"
|
||||
];
|
||||
in
|
||||
''
|
||||
|
|
|
@ -11,12 +11,16 @@ mkCoqDerivation {
|
|||
releaseRev = (v: "v${v}");
|
||||
|
||||
inherit version;
|
||||
defaultVersion = if versions.range "8.12" "8.13" coq.version then "0.1.0" else null;
|
||||
defaultVersion = with versions; switch coq.version [
|
||||
{ case = range "8.12" "8.15"; out = "0.1.1"; }
|
||||
{ case = range "8.12" "8.13"; out = "0.1.0"; }
|
||||
] null;
|
||||
release."0.1.1".sha256 = "sha256:1c0l18s68pzd4c8i3jimh2yz0pqm4g38pca4bm7fr18r8xmqf189";
|
||||
release."0.1.0".sha256 = "sha256:01avfcqirz2b9wjzi9iywbhz9szybpnnj3672dgkfsimyg9jgnsr";
|
||||
|
||||
meta = {
|
||||
description = "Library for serialization to S-expressions";
|
||||
license = licenses.mit;
|
||||
license = licenses.bsd3;
|
||||
maintainers = with maintainers; [ Zimmi48 ];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -11,10 +11,10 @@
|
|||
}:
|
||||
|
||||
let
|
||||
version = "1.23";
|
||||
version = "1.24";
|
||||
prebuilt_server = fetchurl {
|
||||
url = "https://github.com/Genymobile/scrcpy/releases/download/v${version}/scrcpy-server-v${version}";
|
||||
sha256 = "sha256-KpE/1HR4wLMG/KUHywvrYl5JoZ/5/Hq5BONu9bn+fmg=";
|
||||
sha256 = "sha256-rnSoHqecDcclDlhmJ8J4wKmoxd5GyftcOMFn+xo28FY=";
|
||||
};
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
|
@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
|
|||
owner = "Genymobile";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-WR70wV+EfNFFkMFkffnwaTridd33CpJ0zTAlXYyjZgM=";
|
||||
sha256 = "sha256-mL0lSZUPMMcLGq4iPp/IgYZLaTeey9Nv9vVwY1gaIRk=";
|
||||
};
|
||||
|
||||
# postPatch:
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
with lib;
|
||||
|
||||
buildLinux (args // rec {
|
||||
version = "4.14.276";
|
||||
version = "4.14.277";
|
||||
|
||||
# modDirVersion needs to be x.y.z, will automatically add .0 if needed
|
||||
modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg;
|
||||
|
@ -13,6 +13,6 @@ buildLinux (args // rec {
|
|||
|
||||
src = fetchurl {
|
||||
url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz";
|
||||
sha256 = "1rxksrmkh5raz930y9khfg85dglgphrgcvkj21n86m333pajs4mf";
|
||||
sha256 = "058vzn1gcsc194hgwrj78afawz2anm7ga8a1x5m5i4cw8p1arp73";
|
||||
};
|
||||
} // (args.argsOverride or {}))
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
with lib;
|
||||
|
||||
buildLinux (args // rec {
|
||||
version = "4.19.239";
|
||||
version = "4.19.240";
|
||||
|
||||
# modDirVersion needs to be x.y.z, will automatically add .0 if needed
|
||||
modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg;
|
||||
|
@ -13,6 +13,6 @@ buildLinux (args // rec {
|
|||
|
||||
src = fetchurl {
|
||||
url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz";
|
||||
sha256 = "0fsr9jy8d1rpg6ixp7av01pqz3vq50rgfcjd7vj16ccsdk15sz5z";
|
||||
sha256 = "1hj6vngynx6kjaczjl77jjwqq0kh0lm6jdqjvakd1cgrppaizb3j";
|
||||
};
|
||||
} // (args.argsOverride or {}))
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
{ buildPackages, fetchurl, perl, buildLinux, nixosTests, stdenv, ... } @ args:
|
||||
|
||||
buildLinux (args // rec {
|
||||
version = "4.9.311";
|
||||
version = "4.9.312";
|
||||
extraMeta.branch = "4.9";
|
||||
extraMeta.broken = stdenv.isAarch64;
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz";
|
||||
sha256 = "15wqwplq1qk3ni5arfigfl62zbdwhaki3vkg1lv3sln2gnpm059l";
|
||||
sha256 = "09y6wl4j3y46fza6kmssibmxspxx0i44fqrhc2cyvrm2bgxv2bzs";
|
||||
};
|
||||
} // (args.argsOverride or {}))
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
with lib;
|
||||
|
||||
buildLinux (args // rec {
|
||||
version = "5.10.112";
|
||||
version = "5.10.113";
|
||||
|
||||
# modDirVersion needs to be x.y.z, will automatically add .0 if needed
|
||||
modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg;
|
||||
|
@ -13,6 +13,6 @@ buildLinux (args // rec {
|
|||
|
||||
src = fetchurl {
|
||||
url = "mirror://kernel/linux/kernel/v5.x/linux-${version}.tar.xz";
|
||||
sha256 = "19aa7fq8n75gh0vv01mpxg4cxkfpr5lj0sv6lxiyzcgbc71isv4c";
|
||||
sha256 = "1z3dd5hrdbn2axsi2n70n41q1dq2dvg7s8aph1p6yiajpc16llc2";
|
||||
};
|
||||
} // (args.argsOverride or {}))
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
with lib;
|
||||
|
||||
buildLinux (args // rec {
|
||||
version = "5.15.35";
|
||||
version = "5.15.36";
|
||||
|
||||
# modDirVersion needs to be x.y.z, will automatically add .0 if needed
|
||||
modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg;
|
||||
|
@ -15,6 +15,6 @@ buildLinux (args // rec {
|
|||
|
||||
src = fetchurl {
|
||||
url = "mirror://kernel/linux/kernel/v5.x/linux-${version}.tar.xz";
|
||||
sha256 = "1n05c4c4ish25x483a2p5177zgda8pq7g4752n1b7chfygi5l6ha";
|
||||
sha256 = "1466557034q1fzvpy8vwj8ps3cv2q8s7z76af9y1jz4kgaqmsd1n";
|
||||
};
|
||||
} // (args.argsOverride or { }))
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
with lib;
|
||||
|
||||
buildLinux (args // rec {
|
||||
version = "5.17.4";
|
||||
version = "5.17.5";
|
||||
|
||||
# modDirVersion needs to be x.y.z, will automatically add .0 if needed
|
||||
modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg;
|
||||
|
@ -13,6 +13,6 @@ buildLinux (args // rec {
|
|||
|
||||
src = fetchurl {
|
||||
url = "mirror://kernel/linux/kernel/v5.x/linux-${version}.tar.xz";
|
||||
sha256 = "1ifkl1j5dimipqxwki26i4v6gav70g24456y7ynbb71sx1pdag3f";
|
||||
sha256 = "11z95wsgmj97pg77yck26l0383gncbla0zwpzv4gjdj4p62x3g4v";
|
||||
};
|
||||
} // (args.argsOverride or { }))
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
with lib;
|
||||
|
||||
buildLinux (args // rec {
|
||||
version = "5.4.190";
|
||||
version = "5.4.191";
|
||||
|
||||
# modDirVersion needs to be x.y.z, will automatically add .0 if needed
|
||||
modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg;
|
||||
|
@ -13,6 +13,6 @@ buildLinux (args // rec {
|
|||
|
||||
src = fetchurl {
|
||||
url = "mirror://kernel/linux/kernel/v5.x/linux-${version}.tar.xz";
|
||||
sha256 = "157ifcl59xxj721r302hg82vmbqzx5hjrlihrc5s4maxfw3ygm41";
|
||||
sha256 = "0fharjqasvq76pciwci6qamdadpfjh2n8gdyri8fj65drmgsi318";
|
||||
};
|
||||
} // (args.argsOverride or {}))
|
||||
|
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
buildGoModule rec {
|
||||
pname = "godns";
|
||||
version = "2.7.4";
|
||||
version = "2.7.5";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "TimothyYe";
|
||||
repo = "godns";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-0aE+XcRqk/3/auscVdqdzehrpM6CeSdAJTugHXY8rek=";
|
||||
sha256 = "sha256-YQNx0MwdThA2odJMq4rRNOtEe1ul6ICJNLSVr1aqCbA=";
|
||||
};
|
||||
|
||||
vendorSha256 = "sha256-vhByl9oJjFIvOskAgLubZ5RCcitKd2jjxi8D9nU6850=";
|
||||
|
|
Loading…
Reference in a new issue