livekit: add test
This commit is contained in:
@@ -731,6 +731,7 @@ in
|
|||||||
lidarr = handleTest ./lidarr.nix { };
|
lidarr = handleTest ./lidarr.nix { };
|
||||||
lightdm = handleTest ./lightdm.nix { };
|
lightdm = handleTest ./lightdm.nix { };
|
||||||
lighttpd = runTest ./lighttpd.nix;
|
lighttpd = runTest ./lighttpd.nix;
|
||||||
|
livekit = runTest ./networking/livekit.nix;
|
||||||
limesurvey = handleTest ./limesurvey.nix { };
|
limesurvey = handleTest ./limesurvey.nix { };
|
||||||
limine = import ./limine { inherit runTest; };
|
limine = import ./limine { inherit runTest; };
|
||||||
listmonk = handleTestOn [ "x86_64-linux" "aarch64-linux" ] ./listmonk.nix { };
|
listmonk = handleTestOn [ "x86_64-linux" "aarch64-linux" ] ./listmonk.nix { };
|
||||||
|
|||||||
25
nixos/tests/networking/livekit.nix
Normal file
25
nixos/tests/networking/livekit.nix
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
{
|
||||||
|
name = "livekit";
|
||||||
|
meta.maintainers = [ lib.maintainers.quadradical ];
|
||||||
|
|
||||||
|
nodes.machine = {
|
||||||
|
services.livekit = {
|
||||||
|
enable = true;
|
||||||
|
keyFile = pkgs.writers.writeYAML "keys.yaml" {
|
||||||
|
key = "f6lQGaHtM5HfgZjIcec3cOCRfiDqIine4CpZZnqdT5cE";
|
||||||
|
};
|
||||||
|
settings.port = 8000;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
testScript = ''
|
||||||
|
machine.wait_for_unit("livekit.service")
|
||||||
|
machine.wait_for_open_port(8000)
|
||||||
|
machine.succeed("curl 127.0.0.1:8000 -L --fail")
|
||||||
|
'';
|
||||||
|
}
|
||||||
@@ -2,6 +2,7 @@
|
|||||||
lib,
|
lib,
|
||||||
buildGoModule,
|
buildGoModule,
|
||||||
fetchFromGitHub,
|
fetchFromGitHub,
|
||||||
|
nixosTests,
|
||||||
}:
|
}:
|
||||||
|
|
||||||
buildGoModule rec {
|
buildGoModule rec {
|
||||||
@@ -23,6 +24,8 @@ buildGoModule rec {
|
|||||||
mv $out/bin/server $out/bin/livekit-server
|
mv $out/bin/server $out/bin/livekit-server
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
passthru.tests = nixosTests.livekit;
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "End-to-end stack for WebRTC. SFU media server and SDKs";
|
description = "End-to-end stack for WebRTC. SFU media server and SDKs";
|
||||||
homepage = "https://livekit.io/";
|
homepage = "https://livekit.io/";
|
||||||
|
|||||||
Reference in New Issue
Block a user