d5f4a57cbf
GitOrigin-RevId: ce5e4a6ef2e59d89a971bc434ca8ca222b9c7f5e
31 lines
883 B
Nix
31 lines
883 B
Nix
import ./make-test-python.nix ({ lib, ... }:
|
|
{
|
|
name = "chrony";
|
|
|
|
meta = {
|
|
maintainers = with lib.maintainers; [ fpletz ];
|
|
};
|
|
|
|
nodes = {
|
|
default = {
|
|
services.chrony.enable = true;
|
|
};
|
|
graphene-hardened = {
|
|
services.chrony.enable = true;
|
|
services.chrony.enableMemoryLocking = true;
|
|
environment.memoryAllocator.provider = "graphene-hardened";
|
|
# dhcpcd privsep is incompatible with graphene-hardened
|
|
networking.useNetworkd = true;
|
|
};
|
|
};
|
|
|
|
testScript = {nodes, ...} : let
|
|
graphene-hardened = nodes.graphene-hardened.system.build.toplevel;
|
|
in ''
|
|
default.start()
|
|
default.wait_for_unit('multi-user.target')
|
|
default.succeed('systemctl is-active chronyd.service')
|
|
default.succeed('${graphene-hardened}/bin/switch-to-configuration test')
|
|
default.succeed('systemctl is-active chronyd.service')
|
|
'';
|
|
})
|