Sam
Sam

Reputation: 30388

.NET Core Runtime

If I want to create .NET Core 2.0 apps e.g. Console App or ASP.NET Core 2.0, what .NET runtimes do I need installed on my dev machine? I'm on Windows 10.

I created a .NET Core 2.0 Console app to run as a WebJob. In order to zip it up and upload it to Azure, I followed this article: https://learn.microsoft.com/en-us/dotnet/core/deploying/deploy-with-cli#self-contained-deployment-with-third-party-dependencies

When I ran dotnet publish --self-contained -r win32-x64 -c Release I got an error that reads:

Microsoft.NETCore.App.targets(19,5): error : Project is targeting runtime 'win32-x64' but did not resolve any runtime-specific packages for the 'Microsoft.NETCore.App' package. This runtime may not be supported by .NET Core.

But if I run dotnet publish --self-contained -r win10-x64 -c Release, it works fine.

Just want to make sure I'm preparing my app the right way for Azure.

Also I'd like to run my app as 64 Bit, not 32.

Upvotes: 2

Views: 1367

Answers (1)

Martin Ullrich
Martin Ullrich

Reputation: 100543

win32-x64 is not a valid runtime identifier. Use win-x64 instead or see the .NET Core RID Catalog for a list of valid runtime identifiers.

Upvotes: 2

Related Questions