microsoft / PartsUnlimited

.Net Core + SQL Azure app for DevOps Scenarios
https://microsoft.github.io/PartsUnlimited/
MIT License
667 stars 1.53k forks source link

CI and CD with VSTS - Quickstart: Task 7 - no CI build was triggered. #155

Open andresravinet opened 6 years ago

andresravinet commented 6 years ago

After completing all tasks in this lab and the previous, when I reach Task 7 I don't see a release pending in the pipeline nor an email for approval.

spaikles commented 6 years ago

Hi, Silly question: but does the Lab manage to build in VSTS? Is there a artifact?

eamonnk commented 6 years ago

Hi,

Yeah, the lab generates build artifacts and then takes those and deploys to azure. I just ran through it though and the build is breaking, there's been a change affecting one of the tasks. Will have an update shortly to fix it, will let you know what that's done.

Thanks for flagging, Eamonn

andresravinet commented 6 years ago

Thanks! I ended up getting past it and deploying successfully with the help with a colleague. Let me know how I can help.

spaikles commented 6 years ago

So what's the solution then?

eamonnk commented 6 years ago

Just FYI as well that am still working through this, the issue seems to be around node and grunt paths and versions on the agent, don't have an end to end working solution yet to roll out but as soon as I have it I'll share it.

The options I'm working on are some changes to the source files and tasks, or potentially creating our own agent, not using provided hosted agent, and being able to more tightly control the build environment.

I'll possibly be another day or so with it, but if there's any other working solutions in the meantime feel free to share.

Thanks, Eamonn

eamonnk commented 6 years ago

Hi,

Have updated the PartsUnlimitedWebsite.csproj, with the below. The issue was caused by changes in the hosted agent resulting in errors with versions and paths for grunt and python. The below changes will address those it should now run and generate artifacts.

You will see deprecation and some security warnings and some errors as it builds in VSTS but its fine ot ignore those, they don't affect the result and the source files now run and build successfully, have run through it a couple of times and it seems to be running fine with these updated source files.

Have also updated the buld.ps1 verbosity to detailed to provide more output when running, so it may take a small bit longer to run.

Anyway, grab the latest source files and run it with those and let us know if you have any problems.

Thanks, Eamonn

eamonnk commented 6 years ago

just realized the csproj update was commented out, have repasted it below just fyi

\ \ \ \ \ \

thanks again, eamonn

JemDobro commented 5 years ago

I just had this same issue where pushing changes to master was not triggering a CI build.

I believe Task 4 here: http://microsoft.github.io/PartsUnlimited/pandp/200.1x-PandP-CICDQuickstartwithVSTS.html needs to include an instruction (maybe between instruction #8 and #9) to: Click on the "Triggers" tab and make sure the "Branch specification" dropdown says "master".

I checked this when the CI build was not getting triggered, and it said one of the "update - .net core 2" selections I believe. I changed it to master, pushed a code change to master, and CI build was automatically triggered followed by automatic release deployment....working now as expected.

I hope this helps others!