I have solution in Visual Studio which contains three projects: A user interface project, an API project and a project with unit tests. I want to have a github action, which does the following:
- Build everything
- Run the unit tests (currently shared between the UI and API)
- Publish the UI to one Azure Web App
- Publish the API to another Azure Web App
My current yaml build file was auto-generated by Azure when I setup the first web app (the UI) and worked fine. It even ran with the unit tests. But after I added the API I get the following build error:
Error: C:\Users\runneradmin\AppData\Local\Microsoft\dotnet\sdk\6.0.101\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.ConflictResolution.targets(112,5): error NETSDK1152: Found multiple publish output files with the same relative path: D:\a\VirtualScoreCard\VirtualScoreCard\GolfScoreAPI\appsettings.Development.json, D:\a\VirtualScoreCard\VirtualScoreCard\GolfScoreUI\appsettings.Development.json, D:\a\VirtualScoreCard\VirtualScoreCard\GolfScoreAPI\appsettings.json, D:\a\VirtualScoreCard\VirtualScoreCard\GolfScoreUI\appsettings.json. [D:\a\VirtualScoreCard\VirtualScoreCard\UnitTests\UnitTests.csproj]
So it appears that it is somehow trying to push all the projects into the same folder. But how do I get it to build the UI and API to different web apps? And why is it also complaining about the unit tests, when it worked before the API was added?
You can see the yaml file in my github repo.