mirror of
https://github.com/usestrix/strix.git
synced 2026-09-06 08:15:56 +00:00
fix: add initial delay and increase retries for tool server health check
This commit is contained in:
parent
55abf9b55f
commit
f6d15997f0
1 changed files with 3 additions and 1 deletions
|
|
@ -78,10 +78,12 @@ class DockerRuntime(AbstractRuntime):
|
|||
if port_bindings.get(port_key):
|
||||
self._tool_server_port = int(port_bindings[port_key][0]["HostPort"])
|
||||
|
||||
def _wait_for_tool_server(self, max_retries: int = 20, timeout: int = 5) -> None:
|
||||
def _wait_for_tool_server(self, max_retries: int = 30, timeout: int = 5) -> None:
|
||||
host = self._resolve_docker_host()
|
||||
health_url = f"http://{host}:{self._tool_server_port}/health"
|
||||
|
||||
time.sleep(5)
|
||||
|
||||
for attempt in range(max_retries):
|
||||
try:
|
||||
with httpx.Client(trust_env=False, timeout=timeout) as client:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue