Azure / static-web-apps

Azure Static Web Apps. For bugs and feature requests, please create an issue in this repo. For community discussions, latest updates, kindly refer to the Discussions Tab. To know what's new in Static Web Apps, visit https://aka.ms/swa/ThisMonth
https://aka.ms/swa
MIT License
324 stars 56 forks source link

Deployment fails randomly: Deployment Failure Reason: Failure during content distribution. #632

Open meziantou opened 2 years ago

meziantou commented 2 years ago

Describe the bug

The deployment job sometimes fails with the error Deployment Failure Reason: Failure during content distribution. If I retry the GitHub job a few minutes / hours later, it succeeds. It happened a few times this week. The following job succeeds at the 4th attempt.

Run Azure/static-web-apps-deploy@v1
  with:
    azure_static_web_apps_api_token: ***
    repo_token: ***
    action: upload
    app_location: azure-swa
    skip_app_build: true
  env:
    DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1
    DOTNET_NOLOGO: true
    DOTNET_TieredPGO: 1
    ArtifactStagingDirectory: /home/runner/work/project/project/artifacts
    NodeJSVersion: 16
/usr/bin/docker run --name e2849036e93e424f3b45859a9548680c5990b7_f254ff --label e28490 --workdir /github/workspace --rm -e DOTNET_SKIP_FIRST_TIME_EXPERIENCE -e DOTNET_NOLOGO -e DOTNET_TieredPGO -e ArtifactStagingDirectory -e NodeJSVersion -e INPUT_AZURE_STATIC_WEB_APPS_API_TOKEN -e INPUT_REPO_TOKEN -e INPUT_ACTION -e INPUT_APP_LOCATION -e INPUT_OUTPUT_LOCATION -e INPUT_SKIP_APP_BUILD -e INPUT_API_BUILD_COMMAND -e INPUT_API_LOCATION -e INPUT_APP_ARTIFACT_LOCATION -e INPUT_APP_BUILD_COMMAND -e INPUT_ROUTES_LOCATION -e INPUT_CONFIG_FILE_LOCATION -e HOME -e GITHUB_JOB -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_REPOSITORY_OWNER -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RETENTION_DAYS -e GITHUB_RUN_ATTEMPT -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_SERVER_URL -e GITHUB_API_URL -e GITHUB_GRAPHQL_URL -e GITHUB_REF_NAME -e GITHUB_REF_PROTECTED -e GITHUB_REF_TYPE -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e GITHUB_ACTION_REPOSITORY -e GITHUB_ACTION_REF -e GITHUB_PATH -e GITHUB_ENV -e RUNNER_OS -e RUNNER_ARCH -e RUNNER_NAME -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e ACTIONS_CACHE_URL -e GITHUB_ACTIONS=true -e CI=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/_temp/_runner_file_commands":"/github/file_commands" -v "/home/runner/work/project/project":"/github/workspace" e28490:36e93e424f3b45859a9548680c5990b7
DeploymentId: 18676749-2e13-4bf7-a959-a36c86618d04

App Directory Location: 'azure-swa' was found.
No Api directory specified. Azure Functions will not be created.
Looking for event info
Failed to parse GitHub Event Json (/github/workflow/event.json). Proceeding
Could not get event info. Proceeding
Skipping step to build /github/workspace/azure-swa with Oryx
Using 'staticwebapp.config.json' file for configuration information, 'routes.json' will be ignored.
Either no Api directory was specified, or the specified directory was not found. Azure Functions will not be created.
Zipping App Artifacts
Done Zipping App Artifacts
Uploading build artifacts.
Finished Upload. Polling on deployment.
Status: InProgress. Time: 0.0989484(s)
Status: InProgress. Time: 15.2882766(s)
Status: InProgress. Time: 30.4238533(s)
Status: InProgress. Time: 47.2068267(s)
Status: InProgress. Time: 62.6592872(s)
Status: InProgress. Time: 77.91025(s)
Status: InProgress. Time: 93.2929964(s)
Status: InProgress. Time: 108.4562858(s)
Status: InProgress. Time: 123.6240022(s)
Status: InProgress. Time: 138.8958045(s)
Status: InProgress. Time: 154.0757933(s)
Status: InProgress. Time: 169.1921353(s)
Status: InProgress. Time: 184.3383472(s)
Status: InProgress. Time: 199.4665996(s)
Status: Failed. Time: 214.5293545(s)
Deployment Failed :(
Deployment Failure Reason: Failure during content distribution.

For further information, please visit the Azure Static Web Apps documentation at https://docs.microsoft.com/en-us/azure/static-web-apps/
If you believe this behavior is unexpected, please raise a GitHub issue at https://github.com/azure/static-web-apps/issues/
Exiting

Expected behavior The deployment works every time

Screenshots image

miwebst commented 2 years ago

Can you provide any details on the default hostname of the app (i.e. happy-dog-123)? If you do not feel comfortable providing that information here, I'd recommend filing a support request.

meziantou commented 2 years ago

Default hostname: https://zealous-river-050505f0f.azurestaticapps.net

jpalo commented 2 years ago

Getting this same error intermittently as well: icy-sea-009cf3103. Last issue today 3 hours ago. Retrying later or immediately after the error has so far worked, but NOT this time, so unable to deploy updates. Filed support request, will update here of the outcome.

UPDATE: Oh well, 3rd attempt, and it deployed successfully. Will discuss with support anyway...

---End of Oryx build logs---
Finished building app with Oryx
Using 'staticwebapp.config.json' file for configuration information, 'routes.json' will be ignored.
Either no Api directory was specified, or the specified directory was not found. Azure Functions will not be created.
Zipping App Artifacts
Done Zipping App Artifacts
Uploading build artifacts.
Finished Upload. Polling on deployment.
Status: InProgress. Time: 0.3286494(s)
Status: InProgress. Time: 15.6519709(s)
Status: InProgress. Time: 31.0321979(s)
Status: InProgress. Time: 46.4328469(s)
Status: InProgress. Time: 61.7466375(s)
Status: InProgress. Time: 76.9399129(s)
Status: InProgress. Time: 95.337563(s)
Status: InProgress. Time: 110.6155604(s)
Status: InProgress. Time: 125.8977842(s)
Status: InProgress. Time: 141.1042243(s)
Status: InProgress. Time: 156.4833813(s)
Status: InProgress. Time: 171.7872681(s)
Status: InProgress. Time: 187.1270068(s)
Status: Failed. Time: 203.5911316(s)
Deployment Failed :(
Deployment Failure Reason: Failure during content distribution.
whoruyh commented 2 years ago

I am also experiencing the same symptoms. Randomly throws an error. Any solution? image

meziantou commented 2 years ago

Any solution?

Switch to another product... That's what I did as I was unable to reliably deploy my project 😟 But I kept the deploy job on SWA just to see how flaky it is. Maybe I'll switch back to SWA when the job reliably succeeds.

miwebst commented 2 years ago

We are working on a solution, will likely have an update in mid-January. Some things that you can do to improve this reliability in the short term (these may or may not be possible depending on how you build / operate your site):

As I mentioned, these may not be suitable / possible options in which case you will need to wait until mid-January for the fixes we are working on. We apologize for the inconvenience.

vxphuong commented 2 years ago

@miwebst have any update? I met the same issue. image

meziantou commented 2 years ago

@miwebst Any update on the issue?

On my side, the deployment continues to fail almost every day :(

image

Domain: mango-dune-05cf06d10.azurestaticapps.net Deployment Id:

LevYas commented 1 year ago

Also happened to me, two times in a row, DeploymentId: 2f3ba0d0-9f82-4b45-a04d-7396d97dcd2e and DeploymentId: 6f98cdb2-f37e-430f-9db7-bf8f6f311994 Any updates?

jpalo commented 1 year ago

I've had ticket open at Microsoft for over a year. They've promised me several times that "now the issue has been fixed" and that "now your instance has been moved somewhere else and consider yourself privileged as now YOU will no longer see the issue". Yet it still occurs every few weeks. I've always reported the issue to them, but in the last 2 months or so, they haven't even bothered to ackowledge my reports so I'm very confused how come a paid service (I have Standard tier) behaves like this. Bad service, bad support.

akib1997 commented 4 months ago

I am still facing the same issue!

rohanbeemup commented 4 months ago

same here :(

leprechaun19 commented 4 months ago

yes, the same

aherreragrubbrr commented 4 months ago

Same here, it started to fail out of the blue.

karimch27 commented 4 months ago

same here

Aduen commented 4 months ago

yes

akhatri-PXL commented 4 months ago

I am aslo facing the same issue starting today, yesterday it was working.

tge-fyayc commented 4 months ago

Same here! Started this afternoon.

ronit113 commented 4 months ago

same here.

ursaciuc-adrian commented 4 months ago

same here.

Uliura commented 4 months ago

I just recreated the static app, and everything deployed to the fresh app with no errors.

kddsultan commented 4 months ago

The same here. Microsoft has not provided in any Alerts on this

capacit-antonkrogh commented 4 months ago

Same also this afternoon...

karimch27 commented 4 months ago

From Azure : Impact Statement: Starting at 10:02 UTC on 26 Apr 2024, you have been identified as a customer using App Service who may experience issues when attempting to update content for Static Web Apps.Current Status: We are aware of this issue and are actively investigating. The next update will be provided within 60 minutes, or as events warrant.

jgconti commented 4 months ago

Same issue here!

Screenshot 2024-04-26 at 11 18 55 AM

duhseekoh commented 4 months ago

From Azure : Impact Statement: Starting at 10:02 UTC on 26 Apr 2024, you have been identified as a customer using App Service who may experience issues when attempting to update content for Static Web Apps.Current Status: We are aware of this issue and are actively investigating. The next update will be provided within 60 minutes, or as events warrant.

There is clearly an Azure incident taking place -- why is that not reflected here? https://azure.status.microsoft/en-us/status All green?

Ronkiro commented 4 months ago

Also having this problem right now... Certainly an incident

sijojlouis commented 4 months ago

Also having this problem right now... Certainly an incident

+1

kyjovskym commented 4 months ago

+1

bertrand-riviere commented 4 months ago

experience it too :(

Supcar27 commented 4 months ago

just started getting this error on todays deployment

softgandhi commented 4 months ago

+1

btcpbordeaux commented 4 months ago

experiencing the issue as well. have heard diddly-squat from azure about the incident

hewseph commented 4 months ago

+1

Romilkajaria commented 4 months ago

+1

sabupa94 commented 4 months ago

+1

davidpeterko commented 4 months ago

+1

jkuczek15 commented 4 months ago

+1

Alex-atTimec commented 4 months ago

+1

massej commented 4 months ago

+1 here

usapath-mitren commented 4 months ago

+1 has any one heard back from Azure?

twitthoeft-gls commented 4 months ago

+ 1

Geeky2023 commented 4 months ago

Same here for the production env, working fine in other static pages

zrelja commented 4 months ago

+1. Not randomly, every time. Any news from Azure?

jonasacc commented 4 months ago

+1

oscarmendezzavaleta commented 4 months ago

mismo error +1

mikereman commented 4 months ago

+1

Ronkiro commented 4 months ago

From my service integrity's page

Current Status: We are looking into a potential configuration issue at this time. We are continuing to investigate backlogs and telemetry to better understand the issue. Engineers are engaged working on identifying a mitigation workstream at this time. The next update will be provided within 2 hours, or as events warrant.

musaib-js commented 4 months ago

Facing the same error with my deployment. Deployed during the day and it worked fine, but tried deploying new changes now and it has, surprisingly, started giving this error.

jonnydeitos commented 4 months ago

+1