u936293
u936293

Reputation: 16234

Is the .NET Core SDK required for runtime?

I am setting up a Ubuntu machine to deploy a Asp.Net MVC Core app according to the instructions here. In it, it asks for the .NET Core SDK to be installed.

If my server is meant to just run the web application, is it necessary to install the SDK?

Also, if my app is developed in .NET Core 3.0 in Visual Studio, is it ok to have it in a .NET Core 3.1 runtime?

Upvotes: 1

Views: 2950

Answers (2)

jgasiorowski
jgasiorowski

Reputation: 1033

Runtime will be enough to run deployed application https://dotnet.microsoft.com/download/dotnet-core/3.1 In fact you don't even have to do that. Because you can also Publish self-contained package https://learn.microsoft.com/pl-pl/dotnet/core/deploying/#publish-self-contained Which will carry all resources needed for runnint your applicaiton on target OS

v3.1 runtime should support your application built in v3.0

Upvotes: 2

sddk
sddk

Reputation: 1115

From docs;

Install the SDK (which includes the runtime) if you want to develop .NET Core apps. Or, if you only need to run apps, install the runtime. If you're installing the runtime, we suggest you install the ASP.NET Core runtime, as it includes both .NET Core and ASP.NET Core runtimes.

So you do not have to install SDK if you only need to run apps.

You need to install same runtime version as your project (SDK) version

Upvotes: 0

Related Questions