fix(omnivoice): join internal network and fix GPU detection race

Этот коммит содержится в:
2026-09-12 23:25:56 +02:00
родитель 64b586913d
Коммит 35c9fa14de
2 изменённых файлов: 13 добавлений и 0 удалений
+12
Просмотреть файл
@@ -2,6 +2,18 @@
# Starts the FastAPI server; model weights download on first request into /app/models
set -e
# wait for GPU: torch.cuda.is_available() caches its first (possibly premature) result
if [ -e /dev/kfd ]; then
echo "ROCm device detected, waiting for GPU to become available..."
for i in $(seq 1 15); do
if python3 -c "import sys, torch; sys.exit(0 if torch.cuda.is_available() else 1)" 2>/dev/null; then
echo "GPU is available."
break
fi
sleep 1
done
fi
echo "=== OmniVoice Server ==="
echo
+1
Просмотреть файл
@@ -6,6 +6,7 @@ Wants=network-online.target
[Container]
Image=localhost/omnivoice:latest
ContainerName=omnivoice
Network=internal.network
# CPU-only container
#Memory=8g