1{ lib, pkgs, ... }:
2
3let
4 port = 3333;
5in
6{
7 name = "convos";
8 meta.maintainers = with lib.maintainers; [ sgo ];
9
10 nodes = {
11 machine =
12 { pkgs, ... }:
13 {
14 services.convos = {
15 enable = true;
16 listenPort = port;
17 };
18 };
19 };
20
21 testScript = ''
22 machine.wait_for_unit("convos")
23 machine.wait_for_open_port(${toString port})
24 machine.succeed("curl -f http://localhost:${toString port}/")
25 '';
26}