SharePoint / sp-dev-docs

SharePoint & Viva Connections Developer Documentation
https://docs.microsoft.com/en-us/sharepoint/dev/
Creative Commons Attribution 4.0 International
1.23k stars 991 forks source link

Running multi-pages pipelines for SharePoint SPFx #8681

Open Jwaegebaert opened 1 year ago

Jwaegebaert commented 1 year ago

Question originates from @SeeBeeDev in https://github.com/pnp/cli-microsoft365/issues/4309#issue-1518690006


Hi, i would like some help and input on the CI/CD in DevOps using the multi-stages YAML specify in this site > https://learn.microsoft.com/en-us/sharepoint/dev/spfx/toolchain/implement-ci-cd-with-azure-pipelines

I'm able to get this working if my SFPx web part is in it's own DevOps repos. But when i have a repos with multiple folders (web parts), it doesn't able to find the gulp.js or package-locked.json file. (My repos have two webparts and each has it's own folder and i created 3 CI/CD YAML file in a template folder)

image

I got this error referencing the gulp. Do you know fi this YAML is working with folder or has to be on top level?

image

Thanks.

ghost commented 1 year ago

Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.

SeeBeeDev commented 1 year ago

Thanks. At the end i found out the solution by adding this workingDirectory in each of the task so it's able to find the location i needed. Let me know if this is the good way of doing this or it should be better way on this. Thanks heaps.

Do you reckon this 3 YAML files should be use on each web part solution or if we can make the build and deploy template reusable by all SPFx web part we are deploying. thanks.

image