Commit Graph

7 Commits

Author SHA1 Message Date
John Mulligan
7a542b786a github: update mergify rules to handle API vs non-API PRs
This implements the policy first outlined in
https://github.com/ceph/go-ceph/discussions/549

In short: if a PR includes API changes (has the API label) then
either 2 reviews are required or 1 review plus 10 days must pass;
if a PR includes no API changes, then only 1 review is needed.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
2021-08-23 10:14:21 -04:00
Niels de Vos
78f2f30f63 github: require Pacific and dpulls to pass before merging
Tests are running against Ceph Pacific and passing, so this can be
marked as a required CI status.

dpulls handles dependencies between PRs, once the status is marked with
success, the requirements have all been merged. Prevent merging when
dpulls is in a failed state.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2021-05-19 02:15:55 +02:00
John Mulligan
da34b0aec5 github: do not automatically merge on "extended-review" label
The "extended-review" label indicates that review is likely to take
an extended period of time and for bots to not automatically take
a PR.

This avoid the need to preemptively mark a PR as changes needed or
give a false impression with a "do-not-merge" tag, which has a subtle
lack-of-quality implication.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
2021-01-04 14:54:24 -05:00
John Mulligan
2870202d06 github: remove mergify rule checking for mimic as we have removed it
The test case is gone from the CI. Remove it from the merigify config
too.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
2020-12-16 15:18:33 +01:00
Niels de Vos
a5c777bf33 Use Smart-mode for "Strict Merge" to enable automatic rebase
Enabling Smart-mode for "Strict Merge" causes Mergify to do a rebase of
the PR before merging. The rebase will trigger CI runs again, and
merging will be done only when the CI results are successful.

See-also: https://docs.mergify.io/actions.html#merge
Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-11-04 10:01:55 -05:00
Niels de Vos
92b10d8699 Include all status checks explicitly in the Mergify configuration
Unfortunately it is not recommended to use a regular expression to check
for the CI status of multiple tests. In case some tests do not run and
fail to report the status, Mergify will not know something is wrong and
PRs might get merged.

The only way to make sure all status checks have passed successfully, is
to list them all separately.

See-also: https://docs.mergify.io/conditions.html#validating-all-status-check
Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-11-03 12:36:46 -05:00
Niels de Vos
7160ceaa3a Add configuration for Mergify
These rules for Mergify do the following:

1. dismiss review +1's when a PR is updated
   but keep any -1 reviews, so the reviewer needs to confirm the update
   addresses the comment(s)

2. merge the PR when there are 2 (or more) positive reviews, and no
   negative ones
   don't merge when the 'do-not-merge' label is added to the PR
   also require that the status checks (CI) has passed

3. in case there are merge conflicts, Mergify will leave a message
   asking for a rebase

Documentation: https://docs.mergify.io/configuration.html
Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-11-02 09:11:43 -05:00