Exclude topology-attached MCP peers from agent proxy routing#6189
Conversation
|
@copilot resolve the merge conflicts in this pull request |
Addressed in |
Only exempt topology-attached peers (awmg-mcpg, awmg-cli-proxy) from the agent's proxy routing when the agent actually shares awf-net, i.e. a compose-managed runtime (runc, gVisor). For microVM backends (Docker sbx) the agent runs off awf-net and cannot resolve or route to these container hostnames, so injecting them into NO_PROXY there would turn a Squid 403 into an unroutable direct connection. - Gate the exemption on networkIsolation && runtimeUsesComposeAgent so it applies to gVisor and ARC/DinD compose isolation but not sbx. - Defensively exempt difcProxyHost in case the DIFC/cli-proxy is configured independently of topologyAttach. - Document the hostname-only limitation (peer IPs are unknown at config-write time; MCP URLs address peers by hostname). - Add matrix tests: compose isolation (included), difcProxyHost (included), non-isolation (excluded), sbx microVM (excluded). Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 33d45308-d07a-4a8a-887a-dfe16c75efa4
✅ Coverage Check PassedOverall Coverage
📁 Per-file Coverage Changes (3 files)
Coverage comparison generated by |
There was a problem hiding this comment.
Pull request overview
Adds topology-attached peers to agent proxy bypass settings in network-isolation mode.
Changes:
- Extends and deduplicates
NO_PROXYentries. - Excludes unsupported microVM runtimes.
- Adds focused and compose-level regression tests.
Show a summary per file
| File | Description |
|---|---|
proxy-environment.ts |
Adds topology peer proxy bypasses. |
proxy-environment.test.ts |
Tests runtime-specific bypass behavior. |
agent-environment-options.test.ts |
Verifies generated compose environment. |
Review details
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 3/3 changed files
- Comments generated: 1
- Review effort level: Medium
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
|
✅ Copilot review passed with no inline comments. @copilot Add the |
|
✅ Smoke Gemini completed. All facets verified. 💎 |
|
✅ Smoke Copilot BYOK AOAI (Entra) completed. Copilot AOAI BYOK (Entra) mode operational. 🔓 |
|
✅ Smoke Copilot BYOK completed. Copilot BYOK mode operational. 🔓 |
|
📡 Smoke OTel Tracing completed. All tracing scenarios validated. ✅ |
|
📰 VERDICT: Smoke Copilot has concluded. All systems operational. This is a developing story. 🎤 |
|
📰 VERDICT: Smoke Docker Sbx has concluded. All systems operational. This is a developing story. 🎤 |
🔬 Smoke Test Results
Overall: PARTIAL — MCP ✅, pre-step template variables ( Author:
|
Smoke Test: Claude Engine Validation
Overall result: PASS ✅
|
|
Smoke Test: Copilot BYOK (Direct) Mode ✅ PASS
Running in direct BYOK mode (COPILOT_PROVIDER_API_KEY).
|
Smoke Test Results — Services Connectivity
Overall: FAIL —
|
|
|
🔥 AWF Smoke Test — PAT Auth
Overall: PASS (core connectivity tests passed)
|
Chroot Version Comparison ✅
All runtimes match between host and chroot environments.
|
Smoke Test
Warning Firewall blocked 1 domainThe following domain was blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "registry.npmjs.org"See Network Configuration for more information.
|
Smoke Test: API Proxy OpenTelemetry Tracing
Summary: All scenarios pass or are expected-pending. OTEL integration is functional with graceful degradation to file fallback when no collector endpoint is configured.
|
|
Running in direct BYOK mode (AWF_AUTH_TYPE=github-oidc + AWF_AUTH_AZURE_* + COPILOT_PROVIDER_BASE_URL) via api-proxy → Azure OpenAI (Foundry, o4-mini-aw) authenticated via Microsoft Entra Overall status: PASS
|
Smoke Test Results: Gemini Engine
Overall Status: FAIL Warning Firewall blocked 1 domainThe following domain was blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "localhost"See Network Configuration for more information.
|
🏗️ Build Test Suite Results
Overall: 8/8 ecosystems passed — ✅ PASS
|
🧪 Smoke Test Results — Docker Sbx
Overall: PARTIAL PASS — core connectivity verified; pre-step outputs not injected into prompt.
|
In network-isolation mode, the agent container did not exempt topology-attached peers such as
awmg-mcpgfrom proxy routing. Native MCP HTTP connections to gateway-mounted servers were therefore sent through Squid and denied, causing spuriousTCP_DENIEDaudit noise and marking MCP servers as failed during session init.Proxy environment
NO_PROXY/no_proxygeneration to includeconfig.topologyAttachhostnames.localhost, AWF service IPs,api-proxy, host-access entries).Regression coverage
awmg-mcpgandawmg-cli-proxyare present inNO_PROXY.