1import ./make-test-python.nix (
2 { lib, ... }:
3 {
4 name = "chrony";
5
6 meta = {
7 maintainers = with lib.maintainers; [ fpletz ];
8 };
9
10 nodes = {
11 machine = {
12 services.chrony.enable = true;
13
14 specialisation.hardened.configuration = {
15 services.chrony.enableMemoryLocking = true;
16 environment.memoryAllocator.provider = "graphene-hardened";
17 };
18 };
19 };
20
21 testScript = ''
22 machine.start()
23 machine.wait_for_unit('multi-user.target')
24 machine.succeed('systemctl is-active chronyd.service')
25 machine.succeed('/run/booted-system/specialisation/hardened/bin/switch-to-configuration test')
26 machine.succeed('systemctl restart chronyd.service')
27 machine.wait_for_unit('chronyd.service')
28 '';
29 }
30)