diff --git a/adk/compose.yaml b/adk/compose.yaml index 6e8886e9..1e217627 100644 --- a/adk/compose.yaml +++ b/adk/compose.yaml @@ -1,28 +1,35 @@ +version: "3.8" + services: adk: + platform: linux/amd64 build: context: . ports: # expose port for web interface - "8080:8080" environment: - # point adk at the MCP gateway + # point ADK at the MCP gateway - MCPGATEWAY_ENDPOINT=http://mcp-gateway:8811/sse depends_on: - mcp-gateway models: - gemma3 : + gemma3: endpoint_var: MODEL_RUNNER_URL model_var: MODEL_RUNNER_MODEL mcp-gateway: # mcp-gateway secures your MCP servers image: docker/mcp-gateway:latest + platform: linux/amd64 use_api_socket: true + volumes: + # allow gateway to spin up MCP servers via Docker + - /var/run/docker.sock:/var/run/docker.sock:ro + # mount your custom MCP configuration + - ./mcp-config.yaml:/app/config.yaml:ro command: - --transport=sse - # add any MCP servers you want to use - - --servers=duckduckgo models: gemma3: @@ -30,4 +37,4 @@ models: model: ai/gemma3:4B-Q4_0 context_size: 10000 # 3.5 GB VRAM # increase context size to handle search results - # context_size: 131000 # 7.6 GB VRAM + # context_size: 131000 # 7.6 GB VRAM \ No newline at end of file diff --git a/adk/mcp-config.yaml b/adk/mcp-config.yaml new file mode 100644 index 00000000..e4a65246 --- /dev/null +++ b/adk/mcp-config.yaml @@ -0,0 +1,19 @@ +# mcp-config.yaml +hostname: "0.0.0.0" +port: 8811 + +servers: + duckduckgo: + # explicitly tell the gateway how to run the MCP server + command: docker + args: + - run + - --rm + - -i + - --init + - --security-opt=no-new-privileges + - --cpus=1 + - --memory=2Gb + - -e + - DDG_USER_AGENT="Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/115.0.0.0 Safari/537.36" + - mcp/duckduckgo:latest