blob: e78fa3203d04c17c665e7b5a19b34a648aaef30d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
{ pkgs, ... }:
{
name = "bulwark";
meta = with pkgs.lib.maintainers; {
maintainers = [
Cameo007
];
};
nodes.machine = {
services.bulwark = {
enable = true;
settings.allowCustomJmapEndpoint = true;
};
};
testScript = ''
import json
machine.wait_for_unit("bulwark")
machine.wait_for_open_port(3000)
status = machine.succeed("curl -f http://localhost:3000/api/health")
assert json.loads(status)["status"] == "healthy", "The fetched config does not match"
machine.wait_until_succeeds("journalctl -u bulwark | grep -q 'scheduler not started'")
machine.fail("journalctl -u bulwark | grep -q 'init skipped'")
'';
}
|