1{ lib, pkgs, ... }:
2
3{
4 name = "workout-tracker";
5
6 meta.maintainers = with lib.maintainers; [ bhankas ];
7
8 nodes.machine =
9 { config, ... }:
10 {
11 virtualisation.memorySize = 2048;
12
13 services.workout-tracker.enable = true;
14 };
15
16 testScript = ''
17 start_all()
18 machine.wait_for_unit("workout-tracker.service")
19 # wait for workout-tracker to fully come up
20
21 with subtest("workout-tracker service starts"):
22 machine.wait_until_succeeds(
23 "curl -sSfL http://localhost:8080/ > /dev/null",
24 timeout=30
25 )
26 '';
27}