k8s vm tests: create the agent netns before k3s starts a pod, and delete pods strictly again
This commit is contained in:
parent
87349989ac
commit
df4058d2f7
1 changed files with 35 additions and 16 deletions
|
|
@ -127,7 +127,10 @@ pkgs.testers.runNixOSTest {
|
|||
};
|
||||
in
|
||||
{
|
||||
imports = [ self.nixosModules.default ];
|
||||
imports = [
|
||||
self.nixosModules.default
|
||||
./lib/agent-netns.nix
|
||||
];
|
||||
|
||||
services.hyperhive = {
|
||||
deploy.k8s.enable = true;
|
||||
|
|
@ -370,7 +373,6 @@ pkgs.testers.runNixOSTest {
|
|||
with subtest("a client on the hive bridge reaches the control port and is refused at the pods' port"):
|
||||
machine.wait_for_unit("bridge-control.service")
|
||||
machine.succeed(
|
||||
"ip netns add agent; "
|
||||
"ip link add agent0 type veth peer name agent1; "
|
||||
"ip link set agent0 master hive-br0; ip link set agent0 up; "
|
||||
"ip link set agent1 netns agent; "
|
||||
|
|
|
|||
Loading…
Reference in a new issue