tests/nixos/nix-copy: fix NixOS >= 24.05 compatibility

4b128008c5d9fde881ce1b0a25e60ae0415a14d5 in nixpkgs introduced a default
hashedPasswordFile for root in NixOS tests, which takes precedence over
the password option set in the nix-copy test.

Change-Id: Iffaebec5992e50614b854033f0d14312c8d275b5
This commit is contained in:
Pierre Bourdon 2024-06-08 17:57:17 +02:00
parent 4f94531209
commit 9281a12532
Signed by: delroth
GPG key ID: 6FB80DCD84DA0F1C

View file

@ -37,7 +37,8 @@ in {
{ config, pkgs, ... }:
{ services.openssh.enable = true;
services.openssh.settings.PermitRootLogin = "yes";
users.users.root.password = "foobar";
users.users.root.hashedPasswordFile = lib.mkForce null;
users.users.root.password = "foobar";
virtualisation.writableStore = true;
virtualisation.additionalPaths = [ pkgB pkgC ];
};