Skip to content
Agentmart
Submit a tool

azure-container-apps-deployment

Deploy containerized Python apps (FastAPI, RAG, agent backends) to Azure Container Apps with cost optimization for free/student subscriptions.

Skill by RekapalliVasudeva-MBU

IndexedMIT★ 1
Write a review

Chalk Labs

Need help deploying azure-container-apps-deployment?

Chalk Labs sets up agents like this inside real teams: connected to your tools, tested on your data, with a human in the loop where it matters.

Book a call

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/rekapallivasudeva-mbu-azure-container-apps-deployment

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Deploy containerized Python apps (FastAPI, RAG, agent backends) to Azure Container Apps with cost optimization for free/student subscriptions.

Use cases: backend, devops, cloud, ml

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/azure-container-apps-deployment

What's inside

Skill name
azure-container-apps-deployment
Description
Deploy containerized Python apps (FastAPI, RAG, agent backends) to Azure Container Apps with cost optimization for free/student subscriptions.
License
MIT
Instructions
185 lines in SKILL.md · view on GitHub

Before installing

  • Instructions call the network

Files (9)

  • SKILL.md
  • container-app-command-format.md · references/
  • custom-domain-setup.md · references/
  • dockerfile-cpu-only.md · references/
  • docling-import-fix.md · references/
  • github-pages-frontend-update.md · references/
  • healthz-endpoint.md · references/
  • region-policy-workaround.md · references/
  • gh-pages-index.html · templates/

SKILL.md (first lines)

# Azure Container Apps Deployment Skill

Deploy containerized Python apps (FastAPI, RAG, agent backends) to Azure Container Apps with cost optimization for free/student subscriptions.

## When to Use

- Deploying a containerized Python backend (FastAPI, RAG API, agent server) to Azure
- Target is Azure Container Apps (serverless containers, scale-to-zero)
- Subscription has region/policy restrictions (e.g., Azure for Students)
- Need cost optimization: scale-to-zero, no persistent Log Analytics, minimal resources

## Prerequisites

- Azure subscription with Contributor access on a resource group
- Docker image pushed to a public registry (GHCR, Docker Hub) or private ACR
- Azure CLI installed and authenticated (`az login`)
- Resource group created

## Procedure

### 1. Prepare the Docker Image

```dockerfile
# Multi-stage build for minimal size
FROM python:3.11-slim AS builder
RUN apt-get update && apt-get install -y --no-install-recommends gcc g++ libpq-dev && rm -rf /var/lib/apt/lists/*
RUN python -m venv /opt/venv
ENV PATH="/opt/venv/bin:$PATH"
COPY requirements.txt .
RUN pip install --no-cache-dir --upgrade pip setuptools wheel \
    && pip install --no-cache-dir --extra-index-url https://download.pytorch.org/whl/cpu -r requirements.txt

FROM python:3.11-slim AS runtime
RUN apt-get update && apt-get install -y --no-install-recommends libgl1 libgomp1 libpq5 ca-certificates && rm -rf /var/lib/apt/lists/*
COPY --from=builder /opt/venv /opt/venv
ENV PATH="/opt/venv/bin:$PATH"
RUN groupadd -r appuser && useradd -r -g appuser -m -d /home/appuser -s /bin/bash appuser
WORKDIR /app
COPY --chown=appuser:appuser . .
RUN mkdir -p /app/rag_vector_db /app/rag_pdfs /app/dashboard_log && chown -R appuser:appuser /app
USER appuser
ENV PYTHONUNBUFFERED=1 PYTHONDONTWRITEBYTECODE=1 HOST=0.0.0.0 PORT=8000 TOKENIZERS_PARALLELISM=false OMP_NUM_THREADS=1 MKL_NUM_THREADS=1
HEALTHCHECK --interval=30s --timeout=10s --start-period=40s --retries=3 CMD python -c "import urllib.request; urllib.request.urlopen('http://localhost:8000/healthz', timeout=5)" || exit 1
EXPOSE 8000
CMD ["gunicorn", "server:app", "--workers", "1", "--worker-class", "uvicorn.workers.UvicornWorker", "--bind", "0.0.0.0:8000", "--timeout", "120", "--keep-alive", "5", "--max-requests", "1000", "--max-requests-jitter", "50", "--preload"]
```

Key optimizations:
- Use `--extra-index-url https://download.pytorch.org/whl/cpu` for CPU-only PyTorch (avoids CUDA bloat)
- Pin docling version (`docling==1.20.0`) to avoid dependency resolution hell
- Use `gunicorn` with `--preload` for memory sharing
- Single worker, uvicorn worker class
- Health check endpoint `/healthz` (no DB calls)

### 2. Build & Push Image

```bash
docker build -t ghcr.io/<owner>/<repo>:latest .
docker push ghcr.io/<owner>/<repo>:latest
```

Or use GitHub Actions (`.github/workflows/build-push.yml`) for automated builds.

### 3. Create Container Apps Environment (CLI)

**Critical for restricted subscriptions (Azure for Students):**

```bash
# Try Central US first (most commonly allowed)
az containerapp env create --name <env-name> --resource-group <rg> --location "Central US" --logs-destination none

# If Log Analytics required, create workspace in allowed region first:
az monitor log-analytics workspace create --resource-group <rg> --workspace-name <ws-name> --location "Central US"
$workspaceId = az monitor log-analytics workspace show -g <rg> -n <ws-name> --query customerId -o tsv
$workspaceKey = az monitor log-analytics workspace get-shared-keys -g <rg> -n <ws-name> --query primarySharedKey -o tsv
az containerapp env create --name <env-name> --resource-group <rg> --location "Central US" --logs-workspace-id $workspaceId --logs-workspace-key $workspaceKey
```

**Key flags:**
- `--logs-destination none` — skip Log Analytics entirely (saves cost, avoids region restrictions)
- `--logs-workspace-id/key` — use pre-created workspace in allowed region

### 4. Create Container App (CLI)

```bash
az containerapp create \
  --name <app-name> \
  --resource-group <rg> \
  --environment <env-name> \
  --image ghcr.io/<owner>/<repo>:latest \
  --target-port 8000 \
  --ingress external \
  --min-replicas 0 \
  --max-replicas 3 \
  --cpu 1.0 \
  --memory 2Gi \
  --secrets openrouter-api-key="<key>" \
  --env-vars \
    OPENROUTER_API_KEY=secretref:openrouter-api-key \
    RAG_PDF_SOURCE=github \
    RAG_GITHUB_REPO=<owner>/<repo> \
    RAG_GITHUB_PATH=pdfs \
    RAG_GITHUB_REF=main \
    CHROMA_DB_DIR=/data/rag_vector_db \
    HOST=0.0.0.0 \
    PORT=8000
```

**Cost optimization settings:**
- `--min-replicas 0` — scale to zero when idle (no charge)
- `--max-replicas 3` — limit max cost
- `--cpu 1.0 --memory 2Gi` — minimal viable for docling + ChromaDB
- Single container, no sidecars

### 5. Portal Alternative

If CLI fails due to policy, use Azure Portal:
1. **Container Apps Environments** → Create → Region: Central US → Log Analytics: None
2. **Container Apps** → Create → Select environment → Image: `ghcr.io/...` → Ingress: HTTP, port 8000 → CPU: 1, Memory: 2Gi → Min replicas: 0, Max: 3

From RekapalliVasudeva-MBU/aether-desktop, MIT.

More from RekapalliVasudeva-MBU/aether-desktop

Signals

Stars
1
Forks
0
Open issues
0
Last commit (this folder)
Aug 10, 2026 (2 months ago)
Last release
Aug 27, 2026 (2 months ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from RekapalliVasudeva-MBU

Done for you

Rather not set it up yourself?

Chalk Labs scopes, builds and runs agents for your team: the task audit, the eval harness, the integrations and the weekly ops report. Fixed scope, priced before we start.

See how we build AI agents →Read the case studies

Chalk Labs is a two-founder AI and growth studio. We build AI agents, CRMs and MVPs for Web3 and AI companies, and have shipped 50+ product and token launches.

launches shipped
50+
launches shipped
media placements
500+
media placements
founders on every account
2
founders on every account

Press we've placed: Forbes · CoinDesk · Decrypt · Cointelegraph · The Block

Rahil Jain, Co-founder, Chalk Labs. Ex-Goldman Sachs engineer. You talk to the person who builds it.

Get azure-container-apps-deployment running in your business

Tell us what you want to automate. A founder replies within one working day with a plan, not a pitch deck.

Goes to the Chalk Labs founders, not the newsletter. Privacy

Need help deploying azure-container-apps-deployment?

CallGet help
Cite this page

azure-container-apps-deployment skill. Agent Mart. https://agentmart.dev/skills/rekapallivasudeva-mbu-azure-container-apps-deployment (last updated 2026-10-24)