diff --git a/docs/labels.md b/docs/labels.md index d1a43821b3..6eb2694cd1 100644 --- a/docs/labels.md +++ b/docs/labels.md @@ -109,6 +109,7 @@ larger set of contributors to apply/remove them. | `do-not-merge/release-note-label-needed` | Indicates that a PR should not merge because it's missing one of the release note labels.

This was previously `needs/release-note`, | prow | [release-note](https://prow.ci.kubevirt.io/command-help#release-note) | | `do-not-merge/work-in-progress` | Indicates that a PR should not merge because it is a work in progress.| prow | [wip](https://prow.ci.kubevirt.io/command-help#wip) | | `lgtm` | Indicates that a PR is ready to be merged.| reviewers or members | [lgtm](https://prow.ci.kubevirt.io/command-help#lgtm) | +| `needs-approver-review` | Indicates that a PR requires a review from an approver.| prow | [label](https://prow.ci.kubevirt.io/command-help#label) | | `needs-ok-to-test` | Indicates a PR that requires an org member to verify it is safe to test.| prow | [trigger](https://prow.ci.kubevirt.io/command-help#trigger) | | `needs-rebase` | Indicates a PR cannot be merged because it has merge conflicts with HEAD.| prow | [needs-rebase](https://prow.ci.kubevirt.io/command-help#needs-rebase) | | `ok-to-test` | Indicates a non-member PR verified by an org member that is safe to test.| prow | [trigger](https://prow.ci.kubevirt.io/command-help#trigger) | diff --git a/github/ci/prow-deploy/files/jobs/kubevirt/project-infra/project-infra-periodics.yaml b/github/ci/prow-deploy/files/jobs/kubevirt/project-infra/project-infra-periodics.yaml index 8869cdd9a0..e473afb105 100644 --- a/github/ci/prow-deploy/files/jobs/kubevirt/project-infra/project-infra-periodics.yaml +++ b/github/ci/prow-deploy/files/jobs/kubevirt/project-infra/project-infra-periodics.yaml @@ -163,6 +163,41 @@ periodics: - --template - --ceiling=10 - --confirm +- name: periodic-project-infra-needs-approver-review + interval: 1h + annotations: + testgrid-create-test-group: "false" + labels: + preset-github-credentials: "true" + decorate: true + cluster: kubevirt-prow-control-plane + spec: + containers: + - image: gcr.io/k8s-staging-test-infra/commenter:v20240801-a5d9345e59 + command: + - /ko-app/commenter + args: + - |- + --query=org:kubevirt + is:open + is:pr + label:lgtm + -label:approved + -label:do-not-merge/work-in-progress + -label:needs/approver-review + is:public + - --updated=168h + - --token=/etc/github/oauth + - |- + --comment=Pull requests that are marked with `lgtm` should receive a review + from an approver within 1 week. + + After that period the bot marks them with the label `needs-approver-review`. + + /label needs-approver-review + - --template + - --ceiling=10 + - --confirm - name: periodic-project-infra-autoowners interval: 24h annotations: diff --git a/github/ci/prow-deploy/kustom/base/configs/current/labels/labels.yaml b/github/ci/prow-deploy/kustom/base/configs/current/labels/labels.yaml index 059824c7bc..49859456da 100644 --- a/github/ci/prow-deploy/kustom/base/configs/current/labels/labels.yaml +++ b/github/ci/prow-deploy/kustom/base/configs/current/labels/labels.yaml @@ -319,6 +319,12 @@ default: target: prs prowPlugin: lgtm addedBy: reviewers or members + - color: b60205 + description: Indicates that a PR requires a review from an approver. + name: needs-approver-review + target: prs + prowPlugin: label + addedBy: prow - color: 0ffa16 description: Indicates a PR has been approved by an approver from all required OWNERS files. name: approved diff --git a/github/ci/prow-deploy/kustom/base/configs/current/plugins/plugins.yaml b/github/ci/prow-deploy/kustom/base/configs/current/plugins/plugins.yaml index ee998e372c..d1db477319 100644 --- a/github/ci/prow-deploy/kustom/base/configs/current/plugins/plugins.yaml +++ b/github/ci/prow-deploy/kustom/base/configs/current/plugins/plugins.yaml @@ -741,6 +741,9 @@ override: label: restricted_labels: 'kubevirt': + - allowed_users: + - kubevirt-bot + label: needs-approver-review - allowed_teams: - kubevirtorg-label label: good-first-issue