Domain 3 of 4 · Chapter 4 of 4

Configure and deploy Azure function apps

Unlock the complete study guide + 1,040 practice questions across 16 full exams.

Bundled into the existing Developing AI Cloud Solutions on Azure premium course — no separate purchase.

14-day money-back guarantee — no questions asked.

Included in this chapter:

  • What you configure is the app, not the function
  • Five hosting options, and what separates them
  • Cold start, always ready, prewarmed, and Always on
  • How the code gets in: one deploy, zip, and package
  • Remote build or local build, and why Python cares
  • Deployment slots: staging, swapping, sticky settings
  • Application settings, and what the runtime requires
  • Getting secrets out of application settings
  • The host, the Python worker, and the version knobs

The five hosting options, on the axes this page cares about

Hosting optionScale-out behaviorFunction timeout (default / max, minutes)Cold-start mitigationDeployment technology and slots
Flex ConsumptionEvent driven and fast, per-function scaling, to 1,000 instances; scales to zero30 / unboundedAlways ready instances, optional, default 0One deploy only; slots not supported, rolling updates instead
Elastic PremiumEvent driven across the plan; Windows to 100, Linux 20-100 by region; never below one instance30 / unboundedAlways ready instances plus a prewarmed buffer, default 1 prewarmedZip deploy; 3 slots including production
Dedicated (App Service)Manual scale or autoscale, slower than elastic scale; no scale to zero30 / unbounded, and unbounded requires Always onAlways on setting; the host runs continuouslyZip deploy; 1 to 20 slots
Azure Container AppsEvent driven, 300 to 1,000 replicas depending on how the app was created30 / unbounded when minimum replicas is one or moreMinimum replicas of one or more keeps the host runningContainer image; uses revisions rather than slots
Consumption (legacy)Event driven; Windows 200, Linux 100 instances; scales to zero5 / 10Internal placeholder optimization; no always-ready or prewarmed settingZip deploy on Windows, external package URL on Linux; 2 slots

Decision tree

Serverless billing,paying per execution?YesNoMust ship as acontainer image?Reusing existingApp Service capacity?YesNoYesNoAzure Container Appscontainer-only hostmin replicas 0 to idleFlex Consumption planper-function scalingalways ready optionalDedicated (App Service)no scale to zeroenable Always onElastic Premium planEP1, EP2, EP3 SKUsalways ready + prewarmedConsumption plan (legacy)Linux marked Retired and retiring 30 September 2028; no virtual network integration; 10-minute maximumRecognise it in a scenario; do not choose it for a new Python appPython runs on Linux only, so every branch above assumes a Linux app

Cheat sheet

  • The Consumption plan scales to zero and bills per execution, at the cost of cold starts
  • The Premium plan pairs always ready instances with a prewarmed buffer, and adds VNet integration
  • Dedicated (App Service) and Flex Consumption plans trade off predictable capacity vs fast elastic scale
  • The Always On setting exists only on Dedicated plans, not Consumption
  • WEBSITE_RUN_FROM_PACKAGE runs the app from a read-only mounted package, on the plans that allow it
  • func azure functionapp publish deploys the app, using a remote build for Python on Linux
  • Deployment slots let you stage and swap a new build with warm-up and easy rollback
  • Application settings surface as environment variables; AzureWebJobsStorage is required by the runtime
  • Key Vault references let an app setting resolve a secret from Key Vault at runtime without code changes
  • Identity-based (managed identity) connections replace secret connection strings for triggers and bindings
  • Python functions run in a language worker out-of-process, pinned to a supported Functions runtime version
  • The Python v2 programming model defines functions with decorators in function_app.py
  • Python dependencies are declared in requirements.txt and restored during deployment build

Unlock with Premium — includes all practice exams and the complete study guide.

References

  1. Guidance for developing Azure Functions
  2. Azure Functions Scale and Hosting
  3. Deployment technologies in Azure Functions
  4. Azure Functions runtime versions overview
  5. Azure Functions Dedicated hosting
  6. App settings reference for Azure Functions
  7. Azure Functions Flex Consumption plan hosting
  8. Azure Functions Premium plan
  9. Azure Functions on Azure Container Apps
  10. Azure Functions Consumption plan hosting (legacy)
  11. Supported Languages in Azure Functions
  12. Event-driven Scaling in Azure Functions
  13. Azure Functions warmup trigger
  14. Run your Functions from a Package File in Azure
  15. Develop Azure Functions locally using Core Tools
  16. Deploy your Python apps to Azure Functions
  17. Securing Azure Functions
  18. Azure Functions deployment slots
  19. Revisions in Azure Container Apps
  20. Use Key Vault References as App Settings (Azure App Service)
  21. Python developer reference for Azure Functions
  22. Configure connections to remote services in Azure Functions
  23. Environment variables and app settings in Azure App Service
  24. Azure Blob storage trigger with an Event Grid source