#!/usr/bin/env bash # Source from a smoke script; stop only servers below that script's disposable root. stop_fixture_servers() { local fixture_root=$1 fixture_binary=$2 endpoint project while IFS= read -r -d '' endpoint; do project=${endpoint%/.ai-engineering/.local/server/endpoint.json} "$fixture_binary" --project "$project" stop --timeout-seconds 10 >/dev/null || return 1 done < <(find "$fixture_root" -type f -path '*/.ai-engineering/.local/server/endpoint.json' -print0) }