Azure / acr

Azure Container Registry samples, troubleshooting tips and references
https://aka.ms/acr
Other
162 stars 106 forks source link

ACR build fails intermittently because of network issues #733

Closed Costo closed 5 months ago

Costo commented 5 months ago

Describe the bug Hi, I'm currently migrating our Docker builds to az acr build. The builds fail often because of network issues while restoring packages, pulling images or downloading files. Our containers are based on Alpine.

The Docker builds run without issue on my computer. The builds have run without issue for years in Azure Pipelines. This is a new problem that only occur when running the build with az acr build.

Exemple errors:

Step 1/28 : FROM mcr.microsoft.com/azure-cli:2.9.1 as cli
Get 'https://mcr.microsoft.com/v2/': net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers)
2024/01/12 15:39:33 Container failed during run: build. No retries remaining.
failed to run step ID: build: exit status 1
Failed to download package 'Microsoft.AspNetCore.Http.Features.2.1.1' from 'https://api.nuget.org/v3-flatcontainer/microsoft.aspnetcore.http.features/2.1.1/microsoft.aspnetcore.http.features.2.1.1.nupkg'.
  Resource temporarily unavailable (api.nuget.org:443)

Sometimes I can get several successful builds in a row. Sometimes I get several failures in a row.

Any idea what could cause this issue?

To Reproduce Steps to reproduce the behavior:

  1. Run a build in ACR with az acr build
  2. The build randomly fails

Expected behavior The build should succeed

Any relevant environment information

terencet-dev commented 5 months ago

Hi @Costo, apologies for the delay here. Have you opened a support ticket for this yet?

Costo commented 5 months ago

Sorry, I forgot to update the issue. This was resolved after I opened a support ticket. There was a bad deployment in the Canada Central region (and other regions).