nixpkgs/nixos/tests/rtorrent.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

29 lines
495 B
Nix
Raw Permalink Normal View History

{ pkgs, ... }:
let
port = 50001;
in
{
name = "rtorrent";
meta = {
maintainers = with pkgs.lib.maintainers; [ thiagokokada ];
};
2024-06-23 20:38:41 -03:00
nodes.machine =
{ pkgs, ... }:
{
services.rtorrent = {
inherit port;
enable = true;
};
};
testScript = # python
''
machine.start()
machine.wait_for_unit("rtorrent.service")
machine.wait_for_open_port(${toString port})
2024-06-23 20:38:41 -03:00
machine.succeed("nc -z localhost ${toString port}")
'';
}