Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

.NET Core BitBucket Pipeline Builds Fail - Wants project.json when I have .csproj

I was searching before posting but it seems that VS2017 stops using project.json and instead uses .csproj file so when I try to run builds on either TFS or BitBucket, I get fails because the builds are looking for a project.json. Specifically a BitBucket pipeline will tell me that it can't find the project.json in a .Net Core project. Before I could simply run builds without a problem.

I am new to all of this so is this something I have to change or set in the .yml? Or is this something that BitBucket would have to change in their .Net Core pipelines?

Thanks for any assistance on this.

like image 201
Daniel Jackson Avatar asked Mar 23 '17 16:03

Daniel Jackson


2 Answers

Try image: microsoft/dotnet:latest and see if that helps.

like image 76
Ronny Avatar answered Nov 07 '22 08:11

Ronny


Ok so after discussing for a while with bitbucket employees, this image works.

image: microsoft/dotnet:1.1-sdk

BUT that's not all. In the .csproj file there are two sections IF you have your own project files added to the wwwroot, like .css and .js etc files referenced by . The builds were throwing an error on this. I had to comment out that entire to get builds to pass on bitbucket pipelines. I have not seen any downside to doing this as my project still runs as normal and still uses my files. If I run into an issue I will come back and update this answer. But for now this is the solution.

like image 44
Daniel Jackson Avatar answered Nov 07 '22 06:11

Daniel Jackson