feat: point the fleet at wss LiveKit room uwh-telhai

Publish and subscribe over wss://livekit.uni-wh.de:7800 and refuse
cleartext ws://. Conference room is uwh-telhai. Includes the uncommitted
encoded H.264 publish path, Rally hairpin, and KMS wall overlay.
This commit is contained in:
root
2026-10-11 00:48:50 +00:00
parent ef9573c294
commit 95bb7c50ee
89 changed files with 9883 additions and 243 deletions
+77
View File
@@ -0,0 +1,77 @@
#!/usr/bin/env python3
"""Throwaway: one software-encoder publisher reading cam-01 I420 SHM.
Does not open /dev/camNN. Identity spike-sw so it does not kick cam-01.
"""
from __future__ import annotations
import json
import os
import sys
from pathlib import Path
ROOT = Path(__file__).resolve().parents[1]
sys.path.insert(0, str(ROOT))
os.chdir(ROOT)
from config import load_config # noqa: E402
from tokens import make_token # noqa: E402
SHM_DIR = "/run/livekit-cameras/raw"
SRC = f"{SHM_DIR}/cam-01.i420"
LINK = f"{SHM_DIR}/spike-sw.i420"
def main() -> int:
cfg = load_config()
if not os.path.exists(SRC):
print("missing", SRC, file=sys.stderr)
return 1
try:
os.remove(LINK)
except FileNotFoundError:
pass
os.symlink(SRC, LINK)
cam = {
"index": 0,
"identity": "spike-sw",
"video_device": "/dev/null",
"audio_card": None,
"usb_port": "",
"serial": "",
"extra_video_devices": [],
"width": 640,
"height": 360,
"token": make_token(cfg.url, cfg.api_key, cfg.api_secret, cfg.room, "spike-sw"),
}
os.environ.setdefault(
"LIVEKIT_LIB_PATH",
str(ROOT / "native" / "liblivekit_ffi.so"),
)
os.environ.setdefault("LIBVA_DRM_DEVICE", cfg.vaapi_device)
os.environ.setdefault("LIBVA_DRIVER_NAME", "iHD")
argv = [
sys.executable,
str(ROOT / "run_publisher.py"),
"--cameras-json", json.dumps([cam]),
"--url", cfg.url,
"--room", cfg.room,
"--width", "640",
"--height", "360",
"--fps", "30",
"--bitrate", str(cfg.video_bitrate),
"--video-codec", "h264",
"--video-encoder", "software",
"--vaapi-device", cfg.vaapi_device,
"--audio-rate", str(cfg.audio_rate),
"--enhance-mode", "off",
"--beamform-mode", "off",
"--video-shm-dir", SHM_DIR,
"--audio-shm-dir", cfg.audio_shm_dir,
"--encoder-rss-limit-kb", "99000000",
]
os.execv(sys.executable, argv)
if __name__ == "__main__":
raise SystemExit(main())