-
Notifications
You must be signed in to change notification settings - Fork 36
Multi-container setup for agent -> MCP server networking #11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 3 commits
2234cb6
a5902fe
8f0ce4f
58afb4c
7467d92
85a17c1
f3a11c0
d4a8c62
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| .azure | ||
| .venv | ||
| .logfire | ||
| .devcontainer | ||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,37 @@ | ||||||
| # ------------------- Stage 1: Build Stage ------------------------------ | ||||||
| # We use Alpine for smaller image size (~329MB vs ~431MB for Debian slim). | ||||||
| # Trade-off: We must install build tools to compile native extensions (cryptography, etc.) | ||||||
| # since pre-built musl wheels aren't available. Debian -slim would skip compilation | ||||||
| # but produces a larger final image due to glibc wheel sizes. | ||||||
| FROM python:3.13-alpine AS build | ||||||
|
|
||||||
| # Install build dependencies for packages with native extensions (cryptography, etc.) | ||||||
| # https://cryptography.io/en/latest/installation/#building-cryptography-on-linux | ||||||
| RUN apk add --no-cache gcc g++ musl-dev python3-dev libffi-dev openssl-dev cargo pkgconfig | ||||||
|
|
||||||
| COPY --from=ghcr.io/astral-sh/uv:0.9.14 /uv /uvx /bin/ | ||||||
|
|
||||||
| WORKDIR /code | ||||||
|
|
||||||
| # Copy dependency files and install dependencies (for layer caching) | ||||||
| # Note: We avoid --mount=type=cache since Azure Container Apps remote build doesn't support BuildKit | ||||||
|
||||||
| # Note: We avoid --mount=type=cache since Azure Container Apps remote build doesn't support BuildKit | |
| # Note: As of 2024, Azure Container Apps remote build supports BuildKit. Consider using --mount=type=cache to cache package downloads and improve build performance. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added a link to open issue about it
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3,15 +3,24 @@ | |
| name: python-mcp-demo | ||
| metadata: | ||
| template: [email protected] | ||
|
|
||
| services: | ||
| # Not using remoteBuild due to private endpoint usage | ||
| aca: | ||
| server: | ||
| project: . | ||
| language: docker | ||
| host: containerapp | ||
| docker: | ||
| remoteBuild: true | ||
| path: ./servers/Dockerfile | ||
| context: . | ||
| agent: | ||
| project: . | ||
| language: docker | ||
| host: containerapp | ||
| docker: | ||
| remoteBuild: true | ||
| path: ./agents/Dockerfile | ||
| context: . | ||
pamelafox marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| hooks: | ||
| postprovision: | ||
| posix: | ||
|
|
@@ -21,4 +30,4 @@ hooks: | |
| windows: | ||
| shell: pwsh | ||
| run: ./infra/write_env.ps1 | ||
| continueOnError: true | ||
| continueOnError: true | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -26,7 +26,21 @@ module containerAppsEnvironment 'br/public:avm/res/app/managed-environment:0.11. | |
| location: location | ||
| tags: tags | ||
| zoneRedundant: false | ||
| publicNetworkAccess: 'Enabled' | ||
| publicNetworkAccess: usePrivateIngress ? 'Disabled' : 'Enabled' | ||
| workloadProfiles: usePrivateIngress | ||
| ? [ | ||
| { | ||
| name: 'Consumption' | ||
| workloadProfileType: 'Consumption' | ||
| } | ||
| { | ||
| name: 'Warm' | ||
| workloadProfileType: 'D4' | ||
| minimumCount: 1 | ||
| maximumCount: 3 | ||
| } | ||
| ] | ||
| : [] | ||
|
Comment on lines
+30
to
+43
|
||
| appLogsConfiguration: useLogging | ||
| ? { | ||
| destination: 'log-analytics' | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.