How to deploy asp.net core 2.1 preview app to azure?? how do i install the new sdk in azure
Steps to reproduce
i upgraded to .NET Core 2.1 Preview 1 SDK and i installed the asp.net core 2.1 preview site extension by following the instruction on the below link
https://blogs.msdn.microsoft.com/webdev/2018/02/27/asp-net-core-2-1-0-preview1-using-asp-net-core-previews-on-azure-app-service/
Expected behavior
expect the newly released sdk to be installed for azure web app
Actual behavior
running dotnet --info on the web app console screen gives the below result:
D:\home\site\wwwroot
dotnet --info D:\home\site\wwwroot .NET Command Line Tools (2.1.4)
Product Information: Version: 2.1.4 Commit SHA-1 hash: 5e8add2190
Runtime Environment: OS Name: Windows OS Version: 10.0.14393 OS Platform: Windows RID: win10-x86 Base Path: D:\Program Files (x86)\dotnet\sdk\2.1.4\
Microsoft .NET Core Shared Framework Host Version : 2.0.5 Build : 17373eb129b3b05aa18ece963f8795d65ef8ea54
Environment data
dotnet --info output:
anyone knows how to deploy my asp.net core 2.1 preview app to azure?
/cc @glennc
@DebolaA Did stopping and starting the site again make a difference here? If that doesn't change anything then you can check the logs, Logs/SiteExtensions in the Kudu Console as well as the SiteExtensions directory that the extension gets installed into to see if it installed OK. I can find the exact paths you need if you need them.
@glennc no, restarting the site did not make a difference. however, when i checked kudu; i realised the sdk 2.1 preview was installed to SiteExtensions/AspnetRuntime/sdk/
but from running the command dotnet --info; i realised the server is checking D:\Program Files (x86)\dotnet\sdk for the new install.
below is the error message i got when i deploy the web app to azure
D:\Program Files (x86)\dotnet\sdk\2.1.4\Sdks\Microsoft.NET.Sdk\build\Microsoft.NET.TargetFrameworkInference.targets(135,5): error : The current .NET SDK does not support targeting .NET Core 2.1. Either target .NET Core 2.0 or lower, or use a version of the .NET SDK that supports .NET Core 2.1. [D:\home\site\repository\site.csproj]
how do i get the server to look in the right directory?
thank you
@glennc i have gone to
https://
thank you.