Publish .net Core web app as Web Deploy Package (MSDeploy) fails in Visual Studio 2017

660 Views Asked by At

I have created multiple sample project following the VS2017 .Net Core Web App template, targeting .Net Core and .NET Framework.

I have tested in all last three cumulative updates of VS2017; (i.e. Version 15.3.2, 15.3.3, 15.3.4)

Publishing to Web Deploy Package fails with the following error:

Target: .NET Core

   Web deployment task failed. (Could not find file '\PublishTestNetCore.Parameters.xml'.)  PublishTestNetCore  C:\Program Files\dotnet\sdk\1.1.0\Sdks\Microsoft.NET.Sdk.Publish\build\netstandard1.0\PublishTargets\Microsoft.NET.Sdk.Publish.MSDeployPackage.targets  88  

Target: .NET Framework 461

Web deployment task failed. (Could not find file '\TestPublish461.Parameters.xml'.) TestPublish461  C:\Program Files\dotnet\sdk\1.1.0\Sdks\Microsoft.NET.Sdk.Publish\build\netstandard1.0\PublishTargets\Microsoft.NET.Sdk.Publish.MSDeployPackage.targets  88  

I am able to publish to IIS server though, but building the MSDeploy package always fail.

Thanks for any hint.

Mamrez

1

There are 1 best solutions below

0
On

The issue was that the publish to package with latest VS 2017 cumulative updates required .NET Core 2.0 installed and that's odd!

I had to follow this link to install .NET Core 2.0 on my developer laptop to be able to publish MSDeploy packages that target non-.NET Core 2.0!!

[https://www.microsoft.com/net/core#windowscmd]