I'm trying to build my asp.net core application using Jenkins which is hosted with Tomcat8 on an Ubuntu 16.04 machine. The first build succeeds but when starting builds after that they fail (without changing any code) because Jenkins does something weird with the file locations.
The application is being made on a windows machine. After pushing to a git repository Jenkins pulls the source and starts a build. This is the build script I'm using: dotnet restore dotnet build --output "<path to workspace>/build" dotnet publish --output "<path to workspace>/publish" As I said before, the first time this build succeeds and I can deploy my web application. The second time I try to build this is what happens: + dotnet restore Restore completed in 45.32 ms for /usr/share/tomcat8/.jenkins/workspace/Memiro/MemiroFrontend/Memiro.FrontEnd/Memiro.FrontEnd.csproj. Restore completed in 30.38 ms for /usr/share/tomcat8/.jenkins/workspace/Memiro/MemiroFrontend/Memiro.FrontEnd/Memiro.FrontEnd.csproj. [MemiroFrontend] $ /bin/sh -xe /tmp/tomcat8-tomcat8-tmp/jenkins4348889529144999043.sh + dotnet build --output /var/www/dotnet-app/memiro-frontend/build Microsoft (R) Build Engine version 15.3.409.57025 for .NET Core Copyright (C) Microsoft Corporation. All rights reserved. /usr/share/dotnet/sdk/2.0.0/Sdks/Microsoft.NET.Sdk/build/Microsoft.PackageDependencyResolution.targets(323,5): error : Assets file '/usr/share/tomcat8/.jenkins/workspace/Memiro/MemiroFrontend/Memiro.FrontEnd/C:/Users/Hardtraxx/source/repos/MemiroFrontEnd/Memiro.FrontEnd/obj/project.assets.json' not found. Run a NuGet package restore to generate this file. [/usr/share/tomcat8/.jenkins/workspace/Memiro/MemiroFrontend/Memiro.FrontEnd/Memiro.FrontEnd.csproj] /usr/share/dotnet/sdk/2.0.0/Sdks/Microsoft.NET.Sdk/build/Microsoft.PackageDependencyResolution.targets(165,5): error : Assets file '/usr/share/tomcat8/.jenkins/workspace/Memiro/MemiroFrontend/Memiro.FrontEnd/C:/Users/Hardtraxx/source/repos/MemiroFrontEnd/Memiro.FrontEnd/obj/project.assets.json' not found. Run a NuGet package restore to generate this file. [/usr/share/tomcat8/.jenkins/workspace/Memiro/MemiroFrontend/Memiro.FrontEnd/Memiro.FrontEnd.csproj] Build FAILED. For some reason the windows path to the files is appended to the ubuntu path. Why is the windows path appended during the second build? How do I solve this issue? -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/5430eb88-2fa7-4e6a-960a-8c0f2a06eba4%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.