Reputation: 179
I have a multi-stage pipeline, where after successful deploy to QA environment, API tests and E2E tests are run (both of them are in separate repos).
A bug in E2E tests had made them fail, so we fixed it, merged the changes and re-run the E2E stage. The problem is that re-run runs the previous commit (before fixes). The only way we know to run latest commit of E2E tests would be to run all the pipeline again, but it'd take too much time because of long duration of previous stages. Is there a possibility to re-run latest commit without running the whole multi-stage pipeline?
Upvotes: 0
Views: 2410
Reputation: 179
The problem was resolved by adding git pull origin master
step at the beginning.
- ${{ if ne(parameters.checkoutRepository, 'self') }}:
- script: git pull origin master
displayName: Update repository
Upvotes: -1
Reputation: 16238
Is there a possibility to re-run latest commit without running the whole multi-stage pipeline?
Nope. A pipeline run is anchored on the commit which you selected when starting the pipeline. No matter how many times you restart it (or stages of it), it uses the same commit.
//Edit: Actually, depending on your pipeline logic, you could run a new pipeline with only selected stages:
Upvotes: 5