Problem
Creating a new flow fails with:
failed to get primary docker image: network error: failed to reach API server
The flow is written to the database but the worker container never starts.
Environment
PentAGI: 1.1.0-e97bbe5
Host: Kali Linux
Docker: 27.5.1
Install method: docker-compose
OpenAI connectivity test
OpenAI API is reachable from both the main container and worker containers.
Example test from container:
wget -S -qO- --header="Authorization: Bearer $OPEN_AI_KEY" https://api.openai.com/v1/models
Result:
HTTP/1.1 200 OK
Configuration
.env
OPEN_AI_KEY=***
OPEN_AI_SERVER_URL=https://api.openai.com/v1
LLM_SERVER_PROVIDER=openai
LLM_SERVER_MODEL=gpt-4o-mini
LLM_SERVER_URL=https://api.openai.com/v1
LLM_SERVER_KEY=***
DOCKER_ENV_LLM_SERVER_PROVIDER=openai
DOCKER_ENV_LLM_SERVER_MODEL=gpt-4o-mini
DOCKER_ENV_LLM_SERVER_URL=https://api.openai.com/v1
DOCKER_ENV_LLM_SERVER_KEY=***
Logs
flow created in DB flow_id=11 provider_name=openai provider_type=openai
failed to get flow provider
error="failed to get primary docker image: network error: failed to reach API server"
graphql request handled with errors
createAssistant failed to create flow worker
Observation
Worker containers start but environment variables appear empty:
LLM_SERVER_URL=
LLM_SERVER_MODEL=
LLM_SERVER_PROVIDER=
LLM_SERVER_KEY=
Even though they are correctly set in the main container.
Question
Is this related to the automatic Docker image selection step, or is there additional configuration required for worker containers to inherit LLM_SERVER_* variables?