-
Notifications
You must be signed in to change notification settings - Fork 940
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Examples for resource pipeline and source inputs are not clear. #594
Comments
Hi @PramodKumarYadav, thank you for the suggestion! The main goal of the docs is to support collaborative contributions to the design process. For the actual and relevant information you could check the Azure Devops Docs, speaking about the pipeline resources, you could check detailed |
Thanks for the response Dmitrii.
On your above suggestion I would have made a PR but its not clear to me how & what values for these fields should be based on an upstream jobs pipeline. I went through the docs more than a few times and tried some combinations but all of them resulted in error saying "Pipeline Resource trigger-tests-on-merge-to-main Input Must be Valid." Now it could be because of some simple thing missing and I tried a lot of trial and error combinations but since there is no one-to-one reference on the values to be filled in downstream job vs upstream job pipeline source, its not clear to me what is getting missed here and why it is not working. If you can help give me an example and if it works, I will be glad to create a PR to update the docs. Thanks again for looking into it and appreciate your support on this 🙌 |
@PramodKumarYadav Sure, If I understood you correctly, you want to run one pipeline from another, you can check this detailed example as a reference. If you already saw it, could you please write in detail what you want to do, maybe I could help you with it? btw, maybe the problem is that you need to put
|
Hello @DmitriiBobreshev , my use case is to use option number 5 (Pipeline completion triggers) here: I have a "test repository" which contains a pipeline that can run tests. What I want is when an "application" repository pipeline finishes (say for deployment), then I can immediately run my tests in the "test" repository post the application pipeline completion.
P.S: I did include branch name in the pipeline I setup but it didnt work. So maybe a working example that shows how the downsteam (test) repo should refer to resource names in an upstream (app) repo that would be great! |
@PramodKumarYadav, Have you tried to enable build completion triggers using GUI? here you can find the description: https://learn.microsoft.com/en-us/azure/devops/pipelines/process/pipeline-triggers?view=azure-devops |
@DmitriiBobreshev : Classic build triggers are not allowed in our company. So I have to use pipeline triggers and I keep getting this error.
even when I use exactly the same trigger example as specified here: https://learn.microsoft.com/en-us/azure/devops/pipelines/process/pipeline-triggers?view=azure-devops P.S: This has been so much more simpler to setup when I worked with Github Actions. I wish it wasn't so difficult here :). Maybe an example public test repo that shows all these pipelines working examples would be great. Step1:
Step2:
|
Okay, I finally got to make it work but it seems the documentation here would need some updating if others dont go through the same issues.
Now this again is not enough. After user add the correct pipeline name in the source, they would also need to add a pipeline via GUI for these secondary pipeline triggers. Unless we do that the the yaml files in themselves are not enough to trigger the runs (something which works automatically in tools like github action). So unless you add this instruction also in the read me file, it would not work. As a last step, If this trigger should really run "after" the first pipeline is finished then we need to add a trigger: none on the top so that our second pipeline only run one time "after" the first pipeline is finished. If we dont add this our pipeline will run two times. First in parallel to the first line and then again after first pipeline is finished. P.S: If you could ping me the location to update documentation, I will be more than happy to create a PR with detailed instructions on how to do this properly. Hopefully no other user has to face this issue again ever. |
My bad. I see this is the repo where all the documentation is :). I will create a PR right away with detailed examples. Edit: Spoken too soon. I dont see the files for this page in this repo: https://learn.microsoft.com/en-us/azure/devops/pipelines/process/pipeline-triggers?view=azure-devops If you could ping me the repo where this documentation is updated, I will clone and create a PR there. |
Hi @PramodKumarYadav, I'm glad that it finally working! The documentation for ms learn is placed here. You could open most of the ms learn sources by pressing the button |
This issue is with reference to examples listed here: https://github.com/microsoft/azure-pipelines-yaml/blob/master/design/pipeline-resources.md#examples
For example, it is not clear what the distinction between input at "pipeline: SmartHotel" and "source: SmartHotel-CI" from a source side is. If you could given some examples on how to get these names and from where with an example, that would help a lot. Currently its a bit fuzzy and making it difficult to make this part work.
resources:
pipelines:
project: DevOpsProject
source: SmartHotel-CI
branch: releases/M142
The text was updated successfully, but these errors were encountered: