Skip to content

armgit / avibe

Public Imported from GitHub
0

Make your computer a home for your AI partner. Avibe is the local-first Agent OS: Vibey, its built-in AI partner, works out of the box, and Claude Code, Codex & OpenCode run unchanged beside it — reach them from your browser, phone, or any chat app.

fix(e2e): seed default config in entrypoint, skip tests when Docker unavailable

cyh7f8b13415152
diff --git a/scripts/docker-entrypoint.sh b/scripts/docker-entrypoint.sh
index 3c32fcea0..841f161c6 100755
--- a/scripts/docker-entrypoint.sh
+++ b/scripts/docker-entrypoint.sh
@@ -1,8 +1,15 @@
#!/bin/bash
set -e
-# Ensure runtime directories exist
-python -c "from config.paths import ensure_data_dirs; ensure_data_dirs()"
+# Ensure runtime directories exist and seed default config if missing
+python -c "
+from config.paths import ensure_data_dirs, get_config_path
+ensure_data_dirs()
+config_path = get_config_path()
+if not config_path.exists():
+ from vibe.runtime import default_config
+ default_config().save(config_path)
+"
MODE="${1:-ui}"
diff --git a/tests/e2e/conftest.py b/tests/e2e/conftest.py
index cf0ffe8bb..f48da3fba 100644
--- a/tests/e2e/conftest.py
+++ b/tests/e2e/conftest.py
@@ -1,6 +1,7 @@
"""E2E test fixtures: manage Docker container lifecycle."""
import os
+import shutil
import subprocess
import time
@@ -19,6 +20,21 @@ COMPOSE_FILE = os.path.join(os.path.dirname(__file__), "..", "..", "docker-compo
KEEP_CONTAINER = os.environ.get("VIBE_E2E_KEEP", "false").lower() == "true"
+def _docker_available() -> bool:
+ """Check if Docker CLI is installed and the daemon is reachable."""
+ if not shutil.which("docker"):
+ return False
+ try:
+ result = subprocess.run(
+ ["docker", "info"],
+ capture_output=True,
+ timeout=10,
+ )
+ return result.returncode == 0
+ except (OSError, subprocess.TimeoutExpired):
+ return False
+
+
def _url(path: str) -> str:
return f"{E2E_BASE_URL}{path}"
@@ -54,6 +70,9 @@ def _wait_for_healthy(timeout: int = 60) -> bool:
@pytest.fixture(scope="session")
def vibe_container():
"""Start Vibe container for the entire test session, tear down after."""
+ if not _docker_available():
+ pytest.skip("Docker is not available — skipping E2E tests")
+
compose_file = os.path.abspath(COMPOSE_FILE)
env = _compose_env()