Replies: 11 comments 26 replies
-
Without knowing what your Dockerfile looks like, I'm speculating that this is related to a regression in emulation support with NuGet described by NuGet/Home#12227. While that issue describes a specific error versus the hang that you're seeing, I've seen all sorts of unpredictable behavior (both errors and hangs) due to this regression. From a Docker perspective, background on this issue can be found at #4225 and a specific workaround is provided at #4225 (comment). |
Beta Was this translation helpful? Give feedback.
-
I found the proposed work around and it isn't working for my situation. I have a aspnet web server project and several api projects that it relies on. Here is the web server docker file (with the build stuff removed for brevity):
Here is one of the api projects:
When I build this the apis all seem to build fine, but the web server project gives this error:
I am not sure where to go from here. I see that the solution for the user in that other issue was to remove the -r linux-x64 and call out a different source image for the final output. I don't think the slim one will work because this is an aspnet application. I tried to find images that might work for that, but could not determine the exact url. Any thoughts? |
Beta Was this translation helpful? Give feedback.
-
When I set that option on the web server project I get this error:
I also have some more information: Since the api projects seemed to build images without errors (only the web server had issues), I decided to upload the api image to my azure registry and run it. When I did I got an error when it tried to start that was simple that there was an exec format error. I suspect the image ended up with an ARM container / image, so putting the -r tag may not have worked?? |
Beta Was this translation helpful? Give feedback.
-
Created a post here: |
Beta Was this translation helpful? Give feedback.
-
Apologies, I realize I'm a little late to this thread, but the behavior I'm seeing isn't related to the flags shown above. I've posted a repository here with a vanilla Dotnet 7.01 project running on Mac M1. The issue seems to be restricted to docker-compose which isn't able to pick up the platform flag or is dealing with it differently than |
Beta Was this translation helpful? Give feedback.
-
Are you wanting the output from the dotnet command or something that docket
would be logging at the system level?
If the dotnet output I can tell you that nothing its output.
I was able to terminal into the docker container and even with dotnet
restore —verbosity detailed it just locks up and outputs nothing.
…On Fri, Jan 20, 2023 at 6:31 PM Kartheek Penagamuri < ***@***.***> wrote:
@mthalman <https://github.com/mthalman> - How do we capture dump of a
running process (that is executing dotnet restore) in docker container? I
don't know how to capture dumps using dotnet-dump command on docker
containers, hence asking.
—
Reply to this email directly, view it on GitHub
<#4285 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAWFTQ5ELCYMWJXSHBQZI7LWTM4AXANCNFSM6AAAAAATMK5YPY>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Hi, I’m from NuGet.Client team, I got actual stack traces here. |
Beta Was this translation helpful? Give feedback.
-
I posted this statement about .NET docker images and x64 emulation on Apple M1s. That may be related. |
Beta Was this translation helpful? Give feedback.
-
If anybody still is looking for solution, I have fix that using arm64 image for build and publish stage, and amd64 image as base for runtime. Dockerfile:
and run it on Mac M1 with following command: |
Beta Was this translation helpful? Give feedback.
-
We posted a solution at https://devblogs.microsoft.com/dotnet/improving-multiplatform-container-support/ The trick is running the SDK natively with some variant of the following: FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:8.0-preview-alpine AS build |
Beta Was this translation helpful? Give feedback.
-
No effect for my case, I always have to wait like 2 minutes to do the My image is very simple:
|
Beta Was this translation helpful? Give feedback.
-
I originally posted this in the dotnet/sdk github. Then they suggested I post in the NuGet/Home github. They suggested I post here.
dotnet/sdk issue: dotnet/sdk#29610 (comment)
NuGet/Home issue: NuGet/Home#12329
Describe the bug
When I execute the command docker-compose on an asp.net core solution, the dotnet restore step in the build process runs without completing until I ctrl-c the process to stop it.
Expected Behavior
dotnet restore should complete normally
Steps To Reproduce
Create an asp.net core project based on net7 release code.
Add docker support that includes a docker compose file.
Execute docker-compose at the command line.
Notice that the dotnet restore operation runs without completing.
Exceptions (if any)
none
.NET Version
7.0.1
Anything else?
VS4Mac on M1 MacBook pro
This works fine on my Intel MacBook pro for 2016.
Beta Was this translation helpful? Give feedback.
All reactions