Skip to content
alyn
Microsoft Official

Python Appservice Deploy skill

Deploy Python (Flask/Django/FastAPI) code to Azure App Service Linux. WHEN: "Flask App Service", "Django App Service", "FastAPI App Service", "deploy Python to App Service". DO NOT USE FOR: Container Apps, Functions, non-Python, Terraform/Bicep/IaC, full infra — use azure-prepare.

$npx skills add microsoft/azure-skills --skill python-appservice-deploy
View this skill on GitHubmicrosoft/azure-skills/skills/python-appservice-deploy/SKILL.md
Pack stars
1,636
Pack installs
17M
Alyn Score
76/99
Updated
7 h ago
License
MIT
– views – installs via Alyn

Install Python Appservice Deploy

Pick your agent. Every command is ready to paste.

$npx skills add microsoft/azure-skills --skill python-appservice-deploy

The open skills CLI detects your agents (Claude Code, Cursor, Codex and 70+ more) and installs to the right folder. Add -g to install globally.

01

Install it

Run the command above, or upload the folder in Claude.

02

Ask naturally

Describe the task. Your agent loads python-appservice-deploy when the request matches its description.

03

Name it if needed

If it does not trigger, say “use the python-appservice-deploy skill”. In Codex, type $python-appservice-deploy.

The skill itself

SKILL.md

FolderGitHub

Python on Azure App Service — Code Deploy

Deploys Python (Flask, Django, FastAPI, generic) code to Azure App Service Linux (P0v3, Python 3.14). Creates RG + Plan + Web App if missing. Hand off to azure-prepare for VNet, Key Vault, databases, or IaC.

MCP tools used: mcp_azure_mcp_subscription_list, mcp_azure_mcp_group_list, mcp_azure_mcp_appservice, mcp_azure_mcp_azd (when azure.yaml is present).

Workflow

Prerequisite: Verify the latest stable Azure CLI; update with approval and recheck if needed.

  1. Resolve context — smart defaults, minimal prompts. Only the app name is interactive; RG (<app>-rg), Plan (<app>-plan), region (current az default or eastus2), subscription are derived. create-app.md §1.
  2. Detect framework (advisory, never blocks). detect.md.
  3. Choose path — azure.yaml host: appservice → deploy-azd.md; else deploy-azcli.md.
  4. Ensure RG → Plan (P0v3 --is-linux) → Web App (--runtime "PYTHON:3.14") exist. Before creating a plan, invoke azure-quotas to check quota availability. On transient ARM errors, follow transient-retry.md. create-app.md.
  5. Set startup — Flask/Django: none (Oryx auto-detects). FastAPI: always python -m uvicorn main:app --host 0.0.0.0. Other: warn. startup-commands.md.
  6. Set SCM_DO_BUILD_DURING_DEPLOYMENT=true.
  7. Deploy — azd deploy or az webapp deploy --type zip --track-status false --enriched-errors true.
  8. STOP. Print the post-deploy message (post-deploy-message.md) and end the turn.

Hard rules

  • LINUX SCRIPTS — normalize selected shell/startup files to LF, then verify no CR bytes remain. Stop on normalization, validation or packaging failure; deploy only a fresh package.
  • DJANGO REMOTE BUILDS — require STATIC_ROOT and successful system/collectstatic checks before packaging.
  • ⛔ NO POST-DEPLOY VERIFICATION — after deploy returns, do not run az webapp log tail, curl, Invoke-WebRequest, or any health probe. App Service needs 2–3 min to warm; a quiet log or early 5xx is not failure.
  • ⛔ SHELL SAFETY — for --runtime always use "PYTHON:3.14" (colon). Never "PYTHON|3.14" (pipe is a shell operator).
  • ⛔ NEVER az webapp up — deprecated. Use Step 7 commands.
  • ✅ URL FORMAT — present endpoints as https://... URLs.

Error Handling

See errors.md for the full symptom → cause → fix matrix. Quick triage: missing plan/app → re-run Step 4; container ping timeout on 8000 → fix startup (Step 5); ModuleNotFoundError after deploy → ensure Step 6 ran, redeploy.

Tips for Python Appservice Deploy

  • • Start a fresh session after installing so your agent picks up the new skill.
  • • This skill ships scripts. Read them before the first run, and run it in a project without secrets first.
  • • It bundles reference files. The agent reads them only when needed, so they cost no context until then.
  • • It is part of a pack with 30 skills. Install only the ones you need with --skill to keep triggers precise.
  • • If two skills overlap, mention the one you want by name.

Questions about Python Appservice Deploy

What does the Python Appservice Deploy skill do?

Deploy Python (Flask/Django/FastAPI) code to Azure App Service Linux. WHEN: "Flask App Service", "Django App Service", "FastAPI App Service", "deploy Python to App Service". DO NOT USE FOR: Container Apps, Functions, non-Python, Terraform/Bicep/IaC, full infra — use azure-prepare.

How do I install Python Appservice Deploy?

Run "npx skills add microsoft/azure-skills --skill python-appservice-deploy" in your project. The skills CLI installs it for Claude Code, Cursor, Codex and 70+ other agents. In Claude on the web, upload the skill folder as a ZIP under Customize > Skills.

Does Python Appservice Deploy work in Cursor and Codex?

Yes. Python Appservice Deploy uses the open SKILL.md format, so it works in Claude Code, Claude, Cursor, OpenAI Codex, Gemini CLI, GitHub Copilot and other agents that support agent skills.

Is Python Appservice Deploy free?

Python Appservice Deploy is open source on GitHub under the MIT license. It is free to install; check the license before commercial use.

Who made Python Appservice Deploy?

Python Appservice Deploy is published by Microsoft in the microsoft/azure-skills repository, together with 29 other skills.

Similar skills. From other creators.