I'm currently trying out VS2017 at work, due to an interest in migrating our server systems to .Net core. I have switched a couple of minor tools projects to target .NetStandard 1.2 (recreate and move files), and everything builds locally.
However, when I request a build on our TeamCity 10.0.5 server, the build fails with the following message (Project name redacted):
E:\TeamCity\buildAgent1\work\467cb2a824afdbda\Source\{PROJECT FOLDER}\{PROJECT}.csproj error MSB4019: The imported project "C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\Sdks\Microsoft.NET.Sdk\Sdk\Sdk.props" was not found. Confirm that the path in the declaration is correct, and that the file exists on disk.
The folder Microsoft.NET.Sdk does indeed exist on my machine, but not on the build server.
I have installed Build Tools for Visual Studio 2017, and installed .Net Core 1.1 SDK, and the build configuration uses a Visual Studio (sln) runner using VS2017.
What set of tools/installer am I missing?
UPDATE: I've experimented with the Full Visual Studio 2017 installer (community), and the package .NET Framework 4.5 Targeting Pack added the folder in question. Odd, since 4.5 Multi-Targeting pack is already installed on the server.
After setting Build agent to use a full VS2017 community install, a bunch of other issues appeared, such as System namespace not found in the projects in question.
Adding a dotnet restore build step fixed this issue, but then other namespaces where missing (missing installs), and so on.
Building a full framework solution with .NETStandard projects seems to rely on .NET Core to build, which I don't understand, since I'm not targeting .NET Core.