dotnet / core

.NET news, announcements, release notes, and more!
https://dot.net
MIT License
20.92k stars 4.9k forks source link

docker build is throwing error #7133

Open AshrCode opened 2 years ago

AshrCode commented 2 years ago

Problem encountered on https://dotnet.microsoft.com/en-us/learn/aspnet/microservice-tutorial/docker-image Operating System: windows

Error Stack: [+] Building 1.0s (7/14) => [internal] load build definition from Dockerfile 0.0s => => transferring dockerfile: 32B 0.0s => [internal] load .dockerignore 0.0s => => transferring context: 34B 0.0s => [internal] load metadata for mcr.microsoft.com/dotnet/aspnet:6.0 0.5s => [internal] load metadata for mcr.microsoft.com/dotnet/sdk:6.0 0.5s => CANCELED [build 1/6] FROM mcr.microsoft.com/dotnet/sdk:6.0@sha256:e656fe19bc303356acdbfec4695cb2bdd42c7a30677a8775a15eed7fd88edf60 0.1s => => resolve mcr.microsoft.com/dotnet/sdk:6.0@sha256:e656fe19bc303356acdbfec4695cb2bdd42c7a30677a8775a15eed7fd88edf60 0.0s => => sha256:e656fe19bc303356acdbfec4695cb2bdd42c7a30677a8775a15eed7fd88edf60 2.17kB / 2.17kB 0.0s => => sha256:148a3465a035ddc2e0ac2eebcd5f5cb3db715843d784d1b303d1464cd978a391 2.01kB / 2.01kB 0.0s => ERROR [internal] load build context 0.1s => => transferring context: 0.0s => CANCELED [stage-1 1/3] FROM mcr.microsoft.com/dotnet/aspnet:6.0@sha256:bb2428448b9bbc46171905a7a3e8dbdb696a5583e8ba10307f15be4fea8483e9 0.3s => => resolve mcr.microsoft.com/dotnet/aspnet:6.0@sha256:bb2428448b9bbc46171905a7a3e8dbdb696a5583e8ba10307f15be4fea8483e9 0.0s => => sha256:8d32e18b77a4db7f10ec4985cc85c1e385dc6abd16f9573a8c2bc268cad4aab9 3.38kB / 3.38kB 0.0s => => sha256:bb2428448b9bbc46171905a7a3e8dbdb696a5583e8ba10307f15be4fea8483e9 2.17kB / 2.17kB 0.0s => => sha256:5b4a077a17943113fee94818046e6f9839e11ec692481bf122ffacb849cf67de 1.37kB / 1.37kB 0.0s

[internal] load build context:

rpc error: code = Internal desc = stream terminated by RST_STREAM with error code: PROTOCOL_ERROR

AshrCode commented 2 years ago

It's going well with .Net5. Having issues with .Net6 though.

Fydar commented 2 years ago

It looks like something else in your Docker build is failing, which instructs other parts of the build pipeline to be cancelled. The log doesn't tell me anything about what is going on.

Probably best to flag this as NMI.

bartonjs commented 2 years ago

stream terminated by RST_STREAM with error code: PROTOCOL_ERROR

This sounds like something weird went wrong in networking. Is your error still happening? Are there any other errors, like compile errors before the docker phase?

AshrCode commented 2 years ago

stream terminated by RST_STREAM with error code: PROTOCOL_ERROR

This sounds like something weird went wrong in networking. Is your error still happening? Are there any other errors, like compile errors before the docker phase?

Yes, this is still happening. And no, there's no other error before the docker phase. It works perfectly fine if I change it to Net5 instead of Net6.

bartonjs commented 2 years ago

@MichaelSimons Is this sort of docker/build failure something you happen to know off the top of your head, or can otherwise assist with?

MichaelSimons commented 2 years ago

@MichaelSimons Is this sort of docker/build failure something you happen to know off the top of your head, or can otherwise assist with?

Sorry this doesn't look familiar to me. The error makes me suspect docker versus .NET. @AshrCode - are you using the latest docker version?

AshrCode commented 2 years ago

@MichaelSimons Is this sort of docker/build failure something you happen to know off the top of your head, or can otherwise assist with?

Sorry this doesn't look familiar to me. The error makes me suspect docker versus .NET. @AshrCode - are you using the latest docker version?

@MichaelSimons , Yes I am using the latest version of docker.