You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using the .NET SDK to build a container image for a Blazor Web App, and I'm running it on Docker Desktop with WSL2 for local development. My goal is to generate an Entity Framework Core migration bundle during the build process and include it in the container image, then execute the bundle as part of the entrypoint.
The container crashes when it tries to execute ./efbundle, giving the following error message: 2024-10-25 10:20:31 <3>WSL (8) ERROR: UtilGetPpid:1279: Failed to parse: /proc/1/stat, content: 1 (bash) S 0 1 1 0 -1 4194560 566 84 23 3 1 0 0 0 20 0 1 0 1377133 4018176 690 18446744073709551615 94520745209856 94520745999261 140723308442128 0 0 0 65536 4 65538 1 0 0 17 19 0 0 0 0 0 94520746232560 94520746280804 94520777572352 140723308445123 140723308445198 140723308445198 140723308445674 0
If I remove the efbundle from the entrypoint, the container runs successfully, and I can access the Blazor app.
Troubleshooting Steps
Debian VM Test: I tried running ./efbundle in a Debian 12 (Bookworm) VM and initially received a permission error. Running chmod +x efbundle resolved the permission issue, but I then encountered the following error: bash: ./efbundle: cannot execute binary file: Exec format error
Why does the efbundle file fail to execute, even after setting executable permissions? Is there an issue with the file format or target runtime that I'm overlooking?
Is it possible to resolve the permissions issue within the .NET SDK-based container configuration without reverting to a Dockerfile? If not, what would be the recommended way to include and execute the migration bundle? I have seen a similar solution using a Dockerfile here and it looks like permissions are being set so their bundle file and script can be executed.
This is my first time using GitHub so apologies if the question formatting is off.
Any insights or suggestions would be greatly appreciated!
The text was updated successfully, but these errors were encountered:
I'm using the .NET SDK to build a container image for a Blazor Web App, and I'm running it on Docker Desktop with WSL2 for local development. My goal is to generate an Entity Framework Core migration bundle during the build process and include it in the container image, then execute the bundle as part of the entrypoint.
csproj Configuration
Here's a relevant excerpt from my .csproj file:
Docker Compose Configuration
My docker-compose.yml file is set up as follows:
The Problem
The container crashes when it tries to execute ./efbundle, giving the following error message:
2024-10-25 10:20:31 <3>WSL (8) ERROR: UtilGetPpid:1279: Failed to parse: /proc/1/stat, content: 1 (bash) S 0 1 1 0 -1 4194560 566 84 23 3 1 0 0 0 20 0 1 0 1377133 4018176 690 18446744073709551615 94520745209856 94520745999261 140723308442128 0 0 0 65536 4 65538 1 0 0 17 19 0 0 0 0 0 94520746232560 94520746280804 94520777572352 140723308445123 140723308445198 140723308445198 140723308445674 0
If I remove the efbundle from the entrypoint, the container runs successfully, and I can access the Blazor app.
Troubleshooting Steps
bash: ./efbundle: cannot execute binary file: Exec format error
WSL Version: WSL2
Container Base OS: Debian GNU/Linux 12 (Bookworm)
.NET SDK Target Runtime: linux-x64
EF Core Version: 8.0.8
Questions
This is my first time using GitHub so apologies if the question formatting is off.
Any insights or suggestions would be greatly appreciated!
The text was updated successfully, but these errors were encountered: