2023-09-02 20:30:30 +02:00
|
|
|
import ./make-test-python.nix ({ lib, pkgs, ... }: {
|
|
|
|
|
|
|
|
name = "dae";
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
maintainers = with lib.maintainers; [ oluceps ];
|
|
|
|
};
|
|
|
|
|
|
|
|
nodes.machine = { pkgs, ... }: {
|
|
|
|
environment.systemPackages = [ pkgs.curl ];
|
|
|
|
services.nginx = {
|
|
|
|
enable = true;
|
|
|
|
statusPage = true;
|
|
|
|
};
|
|
|
|
services.dae = {
|
|
|
|
enable = true;
|
2023-09-11 18:14:12 +02:00
|
|
|
config = ''
|
2024-08-22 11:09:31 +02:00
|
|
|
global { disable_waiting_network: true }
|
2023-09-11 18:14:12 +02:00
|
|
|
routing{}
|
|
|
|
'';
|
2023-09-02 20:30:30 +02:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
testScript = ''
|
|
|
|
machine.wait_for_unit("nginx.service")
|
|
|
|
machine.wait_for_unit("dae.service")
|
|
|
|
|
|
|
|
machine.wait_for_open_port(80)
|
|
|
|
|
|
|
|
machine.succeed("curl --fail --max-time 10 http://localhost")
|
|
|
|
'';
|
|
|
|
|
|
|
|
})
|