From 9bf49b5daa710510ef8a35e3606a989a9f59260e Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 21 Aug 2026 04:01:48 +0000 Subject: [PATCH] ai-stack: fix invalid YAML in generated docker-compose.yml healthchecks MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Confirmed live: `docker compose pull` failed with "yaml: line 44, column 29: mapping values are not allowed in this context" during the "Starting Stack" phase of local-ai-setup.sh. Root cause: two healthcheck blocks (ollama, chromadb) crammed interval/timeout/retries onto one semicolon-separated line — interval: 30s; timeout: 10s; retries: 5 — which isn't valid YAML; a scalar value can't contain a second `key:` token like that unless quoted. Split each into three separate properly indented keys, matching how every other multi-key block in this same file is written. Verified by generating the actual docker-compose.yml via the real heredoc (same one docker-stack.md's variables would produce) and parsing the result with PyYAML — line 44 is exactly the fixed `interval: 30s` line, and the full file now parses as valid YAML. Pre-existing bug in the vendored source, unrelated to this session's earlier ai-stack.sh/local-ai-setup.sh changes (those only touched the pull-models.sh heredoc and the cloud-provider prompt, both well before this point in the install) — first surfaced now because this is the first run in this session to actually reach the "Starting Stack" step rather than stopping earlier. --- vendor/ai-stack/local-ai-setup.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/vendor/ai-stack/local-ai-setup.sh b/vendor/ai-stack/local-ai-setup.sh index 996867f..49f8dfb 100755 --- a/vendor/ai-stack/local-ai-setup.sh +++ b/vendor/ai-stack/local-ai-setup.sh @@ -596,7 +596,9 @@ services: capabilities: [gpu] healthcheck: test: ["CMD","ollama","list"] - interval: 30s; timeout: 10s; retries: 5 + interval: 30s + timeout: 10s + retries: 5 open-webui: image: ghcr.io/open-webui/open-webui:main @@ -630,7 +632,9 @@ services: - ANONYMIZED_TELEMETRY=FALSE healthcheck: test: ["CMD-SHELL","wget -qO- http://localhost:8000/api/v2/heartbeat || exit 1"] - interval: 15s; timeout: 5s; retries: 5 + interval: 15s + timeout: 5s + retries: 5 rag-server: image: python:3.11-slim