Commit Graph

5 Commits

Author SHA1 Message Date
Yaron Kaikov
cb2c69a3f7 github: mergify: Add Ref to original PR
When openning a backport PR, adding a reference to the original PR.
This will be used later for updating the original PR/issue once the
backport is done (with different label)

Closes scylladb/scylladb#17973
2024-03-25 08:12:47 +02:00
Yaron Kaikov
407d25e47b [mergify] delete backport branch after merge
Since those branches clutter the branch search UI and we don't need them
after merging

Closes scylladb/scylladb#17961
2024-03-22 09:51:22 +02:00
Yaron Kaikov
6406d3083c [mergify] set draft PR when conflicts
When Mergify open a backport PR and identify conflicts, it adding the
`conflicts` label. Since GitHub can't identify conflicts in PR, setting
a role to move PR to draft, this way we will not trigger CI

Once we resolve the conflicts developer should make the PR `ready for
review` (which is not draft) and then CI will be triggered

`conflict` label can also be removed

Closes scylladb/scylladb#17834
2024-03-18 14:45:08 +02:00
Yaron Kaikov
ad842e5ad7 [mergify] Fix worng label and base branch for backport pr
This PR contains 2 fixes for mergify config file:
1) When openning a backport PR base branch should be `branch-x.y`

2) Once a commit is promoted, we should add the label
   `promoted-to-master`, in 5.4 configuraion we were using the wrong
label. fixing it

Closes scylladb/scylladb#17698
2024-03-08 10:08:09 +01:00
Yaron Kaikov
6d07f7a0ea Add mergify (https://mergify.com/) configuration file
In this PR we introduce the .mergify.yml configuration file, which
include a set of rules that we will use for automating our backport
process.
For each supported OSS release (currently 5.2 and 5.4) we have an almost
identical configuration section which includes the four conditions before
we open a backport pr:

* PR should be closed
* PR should have the proper label. for example: backport/5.4 (we can
have multiple labels)
* Base branch should be master
* PR should be set with a promoted label - this condition will be set
automatically once the commits are promoted to the master branch (passed
gating)

Once all conditions are applied, the verify bot will open a backport PR and
will assign it to the author of the original PR, then CI will start
running, and only after it pass. we merge
2024-02-22 14:28:08 +02:00