at master 553 B view raw
1{ 2 lib, 3 ... 4}: 5let 6 port = 43110; 7in 8{ 9 name = "zeronet-conservancy"; 10 meta = with lib.maintainers; { 11 maintainers = [ fgaz ]; 12 }; 13 14 nodes.machine = 15 { pkgs, ... }: 16 { 17 services.zeronet = { 18 enable = true; 19 package = pkgs.zeronet-conservancy; 20 inherit port; 21 }; 22 }; 23 24 testScript = '' 25 machine.wait_for_unit("zeronet.service") 26 27 machine.wait_for_open_port(${toString port}) 28 29 machine.succeed("curl --fail -H 'Accept: text/html, application/xml, */*' localhost:${toString port}/Stats") 30 ''; 31}