1.7 KiB
1.7 KiB
lightscale lab (NixOS VMs)
This folder contains NixOS tests that boot QEMU VMs, register them against the lightscale control plane, bring up WireGuard interfaces, and verify ping across overlay IPs.
Run the lab test
Fast (2 nodes) test to avoid long builds:
cd /home/centra/dev/lightscale
nix build .#nixosTests.lightscale-lab
./result/bin/nixos-test-driver
Or use the helper script (prebuilds client/server first):
cd /home/centra/dev/lightscale
./lab/run.sh
To watch logs interactively (recommended when debugging hangs):
cd /home/centra/dev/lightscale
./lab/run.sh --interactive --keep
In the Python prompt, run:
node1.execute("tail -f /tmp/lightscale-server.log")
Full (5 nodes) test:
cd /home/centra/dev/lightscale
nix build .#nixosTests.lightscale-lab-5
./result/bin/nixos-test-driver
Helper script:
cd /home/centra/dev/lightscale
./lab/run.sh full
Firewall (UDP blocked, stream relay fallback):
cd /home/centra/dev/lightscale
./lab/run.sh firewall
Control plane restart/outage resilience:
cd /home/centra/dev/lightscale
./lab/run.sh controlplane
Control plane HA (shared DB + client failover across control URLs):
cd /home/centra/dev/lightscale
./lab/run.sh controlplane-ha
Stream relay failover (multi relay servers, first down):
cd /home/centra/dev/lightscale
./lab/run.sh relay-failover
The tests will:
- start node1 as the control server
- register clients
- run
agenton each node (endpoint rotation + stream relay fallback phases) - ping full-mesh between overlay IPv4 addresses in both phases
- for the firewall test, block UDP/51820 between nodes and verify stream relay fallback