What is Container Apps?
Container Apps runs containers without requiring you to manage any Kubernetes infrastructure. It's built on AKS under the hood but abstracts it completely. You just provide a container image and configuration.
| Feature | ACI | Container Apps | AKS |
|---|---|---|---|
| Kubernetes management | None | None (abstracted) | Full control |
| Scale to zero | Manual stop | ✅ Automatic | ✅ With KEDA |
| Traffic splitting | ❌ | ✅ Built-in revisions | ✅ With Ingress |
| Dapr support | ❌ | ✅ Built-in | ✅ Self-install |
| Best for | One-off tasks, simple workloads | Microservices, APIs, event processing | Complex enterprise workloads |
Environments and Apps
Container Apps has two levels:
- Container Apps Environment — A shared boundary for a group of container apps. Apps in the same environment share a VNet, logging, and can communicate internally.
- Container App — An individual application within an environment. Each app runs one container image and can have multiple revisions.
Scaling
Container Apps scales automatically based on:
| Scale Trigger | Example |
|---|---|
| HTTP requests | Scale out when concurrent requests exceed threshold |
| CPU / Memory | Scale out when CPU exceeds 70% |
| Azure Service Bus | Scale based on queue message count |
| Azure Event Hubs | Scale based on consumer lag |
| Custom (KEDA) | Any KEDA-supported scaler |
Container Apps can scale to zero — no replicas, no cost — when there are no requests or events. This makes it very cost-efficient for sporadic workloads.
Revisions and Traffic Splitting
Every time you update a container app, a new revision is created — an immutable snapshot of the app configuration. You can split traffic between revisions for blue-green deployments or A/B testing:
# Deploy new revision (v2) with 20% of traffic
az containerapp ingress traffic set \
--name myapp \
--resource-group myRG \
--revision-weight \
myapp--v1=80 \
myapp--v2=20
# When confident, send 100% to v2
az containerapp ingress traffic set \
--name myapp \
--resource-group myRG \
--revision-weight myapp--v2=100
Ingress
Container Apps supports two ingress modes:
- External — Accessible from the internet via a public FQDN (
myapp.happyplant-abc123.centralindia.azurecontainerapps.io) - Internal — Only accessible from within the Container Apps Environment — for internal microservices
Dapr Integration
Dapr (Distributed Application Runtime) is a set of building blocks for microservices — service-to-service invocation, state management, pub/sub, bindings. Container Apps has Dapr built in — enable it with one flag and your apps get all Dapr capabilities without running a sidecar yourself:
az containerapp update \
--name myapp \
--resource-group myRG \
--enable-dapr \
--dapr-app-id myapp \
--dapr-app-port 3000
Creating via CLI
# Create Container Apps environment
az containerapp env create \
--name myEnvironment \
--resource-group myRG \
--location centralindia
# Create container app
az containerapp create \
--name myapp \
--resource-group myRG \
--environment myEnvironment \
--image myregistry.azurecr.io/myapp:v1 \
--registry-server myregistry.azurecr.io \
--registry-identity system \
--target-port 3000 \
--ingress external \
--min-replicas 0 \
--max-replicas 10 \
--cpu 0.5 \
--memory 1.0Gi \
--env-vars NODE_ENV=production