Skip to content

Commit 2df9ed5

Browse files
cbeauchesnedevflow.devflow-routing-intake
andauthored
Add team freeze guard workflow (#12437)
Add team freeze guard workflow Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Rename file to .yaml Update .github/workflows/README.md, Update TFG to 0.0.4 Co-authored-by: devflow.devflow-routing-intake <devflow.devflow-routing-intake@kubernetes.us1.ddbuild.io>
1 parent 59b0330 commit 2df9ed5

2 files changed

Lines changed: 51 additions & 0 deletions

File tree

.github/workflows/README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,16 @@ _Recovery:_ Re-write the new Groovy files in Java / JUnit. To override this chec
129129

130130
_Notes:_ The override label skips the workflow entirely.
131131

132+
### team-freeze-guard [🔗](team-freeze-guard.yaml)
133+
134+
_Trigger:_ When a pull request is opened, reopened, synchronized, labeled, unlabeled, or marked ready for review.
135+
136+
_Action:_ Fail the check if the pull request author or the last committer belongs to a team currently listed in the `frozen-teams` input, blocking the PR from merging.
137+
138+
_Recovery:_ If your PR is not dedicated to fix CI issue, it'll be block until the incident is resolved. If your Pr aims to fix CI issues, add one of the configured labels: `comp: testing`, `comp: tooling`, `tag: flaky test`, `tag: flaky test/disabled` to the pull request.
139+
140+
_Notes:_ Configure frozen teams by editing the `frozen-teams` input in the workflow file (empty string means no team is frozen; otherwise list `@DataDog/<team>` entries one per line).
141+
132142
## Code Quality and Security
133143

134144
### analyze-changes [🔗](analyze-changes.yaml)
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# How to configure:
2+
#
3+
# When no team is frozen, set `frozen-teams` to an empty string:
4+
# frozen-teams: ""
5+
#
6+
# When one or more teams are frozen, add them one per line with the @DataDog prefix:
7+
#
8+
# frozen-teams: |
9+
# @DataDog/team-a
10+
# @DataDog/team-b
11+
12+
name: Team freeze guard
13+
14+
on:
15+
pull_request_target:
16+
types:
17+
- opened
18+
- reopened
19+
- synchronize
20+
- labeled
21+
- unlabeled
22+
- ready_for_review
23+
24+
permissions:
25+
id-token: write
26+
contents: read
27+
28+
jobs:
29+
team-freeze-guard:
30+
name: Team freeze guard
31+
runs-on: ubuntu-latest
32+
33+
steps:
34+
- uses: DataDog/team-freeze-guard@e4ff51a72cac229b238e5a302af0d3d955ae5b54 # v0.0.4
35+
with:
36+
bypass-labels: |
37+
comp: testing
38+
comp: tooling
39+
tag: flaky test
40+
tag: flaky test/disabled
41+
frozen-teams: ""

0 commit comments

Comments
 (0)