Class library references in API Project not found in Docker
I'm getting this error:
warning MSB3202: The project file "C:\Bonus.Domain\Bonus.Domain.csproj" was not found. [C:\app\Bonus.API.csproj]
This is not the path to my class library. Before I go further I want to share I am using Microsoft's eShopOnContainers as my reference while building my project.
The path that docker uses to find the class library is the projectreference in my csproj file. If I change that the error reflects the new pathing in the error. Right now I have it set up as:
<ProjectReference Include="..\Bonus.Domain\Bonus.Domain.csproj" />
This is same way eShop has it. However when I compose eShop it has the correct pathing
c:\dev\netproject\projectname\domain.csproj
instead of something like the error
c:\projectname\domain.csproj
If I change my pathing to a more direct path:
<ProjectReference Include="c:\dev\netprojects\projectname\Bonus.Domain\Bonus.Domain.csproj" />
It still gives me the same error and I think this sheds light on something strange happening. The end of the error says:
[C:\app\Bonus.API.csproj]
This pathing does not exist on my computer. I am not an expert with docker, but it seems like docker has a virtual c drive and is searching that for the class library only within my project buy Microsoft's project is searching the physical drive. Is that a possibility?
0 comments:
Post a Comment