forked from mirrors/nixpkgs
Merge pull request #235972 (fix Taskserver test)
I'm merging this without review, since the tests run by ofborg are succeeding. In addition to that, it's fixing a currently broken test so the worst that could happen is that the test still does not work.
This commit is contained in:
commit
c14dac6f25
|
@ -69,23 +69,14 @@ in {
|
|||
testOrganisation.users = [ "alice" "foo" ];
|
||||
anotherOrganisation.users = [ "bob" ];
|
||||
};
|
||||
};
|
||||
|
||||
# New generation of the server with manual config
|
||||
newServer = { lib, nodes, ... }: {
|
||||
imports = [ server ];
|
||||
services.taskserver.pki.manual = {
|
||||
ca.cert = snakeOil.cacert;
|
||||
server.cert = snakeOil.cert;
|
||||
server.key = snakeOil.key;
|
||||
server.crl = snakeOil.crl;
|
||||
};
|
||||
# This is to avoid assigning a different network address to the new
|
||||
# generation.
|
||||
networking = lib.mapAttrs (lib.const lib.mkForce) {
|
||||
interfaces.eth1.ipv4 = nodes.server.config.networking.interfaces.eth1.ipv4;
|
||||
inherit (nodes.server.config.networking)
|
||||
hostName primaryIPAddress extraHosts;
|
||||
specialisation.manual-config.configuration = {
|
||||
services.taskserver.pki.manual = {
|
||||
ca.cert = snakeOil.cacert;
|
||||
server.cert = snakeOil.cert;
|
||||
server.key = snakeOil.key;
|
||||
server.crl = snakeOil.crl;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -103,7 +94,8 @@ in {
|
|||
testScript = { nodes, ... }: let
|
||||
cfg = nodes.server.config.services.taskserver;
|
||||
portStr = toString cfg.listenPort;
|
||||
newServerSystem = nodes.newServer.config.system.build.toplevel;
|
||||
specialisations = "${nodes.server.system.build.toplevel}/specialisation";
|
||||
newServerSystem = "${specialisations}/manual-config";
|
||||
switchToNewServer = "${newServerSystem}/bin/switch-to-configuration test";
|
||||
in ''
|
||||
from shlex import quote
|
||||
|
|
Loading…
Reference in a new issue