A team needs Container Apps with private access to a database. How do you set up networking?
IntermediateScenarioNetworking Design
Answer
Situation read → Container Apps environment injected into a VNet subnet, internal or external ingress, DB via Private Endpoint.
What I'd do →
- Create a dedicated subnet (
/27minimum for workload profiles environments) delegated toMicrosoft.App/environments - Create the environment with
--infrastructure-subnet-resource-idand--internal-onlyif no public ingress is needed - Database Private Endpoint in the same VNet, Private DNS zone linked
- Connect the app with managed identity where the DB supports Entra auth
- If internal-only, create a Private DNS zone for the environment's default domain pointing to its static IP
Why → Workload profiles environments support UDRs and NAT Gateway, so egress control works like the rest of the spoke.
Interview tip → Mention the environment's own DNS zone for internal-only setups; it's often forgotten.
More on Networking Design
Design the network for a new three-tier app in Central India that must be private except for the web front end.IntermediateSpoke A can't talk to spoke B, both peered to the hub. What design change makes it work?BeginnerWorkloads must reach Azure SQL privately, including from on-prem over ExpressRoute. How do you set it up?AdvancedYou need all outbound traffic from AKS to go through Azure Firewall. How do you do it?AdvancedA partner needs to whitelist a single egress IP from your App Service and AKS workloads. How?IntermediateYou're asked to expose an internal API to a customer's Azure tenant without VNet peering. How?Advanced