Managed Functions deployment consistently fails with "Failed to deploy the Azure Functions" on Free tier — reproducible with zero-dependency function
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 25/100
- Tipo di issue
- Bug
- Chiarezza
- Da chiarire
- Stato di attività
- Attiva
- Stack tecnologico
- azure, node.js, typescript
Direzione di ricerca
Inizia riproducendo il comando swa deploy ./dist --api-location ./api con l’API minima, la risorsa Free-tier e il token di distribuzione descritti qui. Confronta il percorso di distribuzione dell’API con la distribuzione riuscita del solo frontend e ispeziona staticwebapp.config.json, host.json e i contenuti generati di dist/. Il lavoro è completo quando viene identificata una causa riproducibile nella CLI o nella piattaforma, oppure quando la restrizione viene documentata e l’errore generico viene sostituito con evidenze utili.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Summary
Every attempt to deploy an API (managed Azure Functions, via swa deploy --api-location) to a Free-tier Static Web App fails with the generic "Failed to deploy the Azure Functions" reason, after a consistent ~16 second delay. Frontend-only deployment (no --api-location) succeeds without issue on the same resource.
Environment
- Static Web App SKU: Free
- Region: East US 2 (also tried West Europe / North Europe, both rejected at creation time with "region not accepting new customers" — unrelated to this issue)
- SWA CLI version: 2.0.10
- Node.js API,
apiVersion: 22(also tried with explicit"platform": {"apiRuntime": "node:22"}in staticwebapp.config.json — no change) - Deployment method:
swa deploywith a deployment token (not GitHub Actions) - OS: Windows 11
Steps to reproduce
- Create a Free-tier Static Web App via
az staticwebapp create. - Create a minimal API with a single HTTP-triggered function, zero dependencies beyond
@azure/functions. - Build it (
tsc), producing a cleandist/with one compiled function file andhost.jsonat the API root. - Deploy:
swa deploy ./dist --api-location ./api --deployment-token <token> --env production
Expected
The single trivial function deploys successfully.
Actual
Deployment fails every time, identically:
Troubleshooting already done
- Confirmed not a stale-build-artifact issue (clean
dist/, verified exact file list before zipping). - Confirmed not a bloated/dev-dependency issue (
npm prune --omit=devbefore deploy). - Confirmed not a runtime-version issue (Node 22 is on the documented supported list; explicit
apiRuntimeconfig made no difference). - Confirmed not specific to one resource instance: fully deleted and recreated the Static Web App, identical failure on the fresh resource.
- Confirmed not specific to our actual application code: deployed a single-endpoint function with zero dependencies beyond
@azure/functions, identical failure. - Frontend-only deployment (same resource,
swa deploy ./distwithout--api-location) succeeds cleanly every time. - Azure Portal's Activity Log shows no entry corresponding to this failure (deployment appears to go through a non-ARM data-plane path not captured there).
- Azure Portal's "Diagnose and solve problems" tool for the resource did not surface anything more specific.
This strongly suggests either a platform-side issue specific to this subscription/tier combination, or an undocumented restriction on managed Functions for Free-tier Static Web Apps that isn't reflected in current error messaging.
- Lingua principale
- Nessun dato sulla lingua
- Stelle
- 347
- Fork
- 68
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di Azure/static-web-apps
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
Azure/static-web-apps#1764 · 2 commenti ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 25/100
Azure/static-web-apps#1827 ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
Azure/static-web-apps#1826 · 5 commenti · 1 reazione ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 42/100
Azure/static-web-apps#1825 ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 18/100
Azure/static-web-apps#1824 ·
Tutte le issue di Azure/static-web-apps
Issue simili
-
component/media domain/discovery
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
I maintainer di solito rispondono entro 1 giorno
-
roadmap/v1.2.0 type/bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
databrickslabs/ontos#1773 ·
I maintainer di solito rispondono entro 2 giorni
-
bug good first issue help wanted up-for-grabs
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
ClickHouse/loom#2075 ·
I maintainer di solito rispondono entro 1 giorno
-
[Bug]: The trt-decoder extra installs TensorRT 11, which the trt_decoder plugin cannot loadForse già presa @fedonman l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100