Hi everyone,
I've set up Bitbucket Pipelines for my repositories, I'm using scheduled pipelines to run unit tests and regression tests overnight.
The current problem is that the scheduled pipeline runs multiple times for the same commit. This is wasting my minutes and would like to know if there is any known way to stop this from happening.
Here's my bitbucket-pipelines.yml:
image: ruby:2.4.0 pipelines: custom: develop: - step: script:
- do stuff
Thank You.
Gabriel, I know this is an old thread, but did you solve your issue? I am having a similar problem. Thanks!
Adding onto Aneita's response. You can use the Bitbucket REST API as a workaround if this is important functionality for you. But this will be a bit more work to set up (and may not suit your specific use-case).
You can use the build status API to check if another Pipelines has been run against the commit that's currently being tested. At the start of your pipeline you can check this and then stop earlier if there's already a pipeline against that commit.
Build Status API: https://developer.atlassian.com/bitbucket/api/2/reference/resource/repositories/%7Busername%7D/%7Brepo_slug%7D/commit/%7Bnode%7D/statuses/build
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Gabriel,
There currently isn't a way to prevent scheduled pipelines from running on the same commit. We do have an open request to improve this. I encourage you to vote for that issue and add a comment with your use case if it is something that you would like to see.
Thanks,
Aneita
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.