Skip to content

Commit

Permalink
Add prow-github-action
Browse files Browse the repository at this point in the history
Signed-off-by: Sivanantham Chinnaiyan <[email protected]>
  • Loading branch information
sivanantha321 committed Aug 16, 2024
1 parent f9c73c2 commit 3705343
Show file tree
Hide file tree
Showing 4 changed files with 92 additions and 0 deletions.
31 changes: 31 additions & 0 deletions .github/labels.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Labels for labeling issues and pull requests using GitHub prow action.
kind:
- 'bug'
- 'discussion'
- 'feature'
- 'process'
- 'question'

area:
- 'api'
- 'azure'
- 'docs'
- 'example'
- 'gcp'
- 'inference'
- 'infrastructure-feature'
- 'logging'
- 'operator'
- 'performance'
- 'testing'
- 'project-health'
- 'servingruntime'
- 'inferencegraph'
- 'storage'
- 'inferenceservice'
- 'control-plane'

priority:
- 'p0'
- 'p1'
- 'p2'
30 changes: 30 additions & 0 deletions .github/workflows/prow-github.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Run specified actions or jobs for issue and PR comments

name: "Prow github actions"
on:
issue_comment:
types: [created]

jobs:
execute:
runs-on: ubuntu-latest
steps:
- uses: jpmcb/prow-github-actions@latest
with:
prow-commands: '/assign
/unassign
/approve
/retitle
/area
/kind
/priority
/remove
/lgtm
/close
/reopen
/lock
/milestone
/hold
/cc
/uncc'
github-token: "${{ secrets.GITHUB_TOKEN }}"
17 changes: 17 additions & 0 deletions .github/workflows/prow-pr-automerge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# This Github workflow will check every hour for PRs with the lgtm label and will attempt to automatically merge them.
# If the hold label is present, it will block automatic merging.

name: "Merge on lgtm label"
on:
schedule:
- cron: "0 * * * *" # every hour

jobs:
execute:
runs-on: ubuntu-latest
steps:
- uses: jpmcb/prow-github-actions@v1
with:
jobs: 'lgtm'
github-token: "${{ secrets.GITHUB_TOKEN }}"
merge-method: 'squash'
14 changes: 14 additions & 0 deletions .github/workflows/prow-pr-remove-lgtm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# This workflow will remove the lgtm label from a PR that gets updated.
# This prevents any un-reviewed code from being automatically merged by the lgtm-merger mechanism.

name: "Remove lgtm label"
on: pull_request

jobs:
execute:
runs-on: ubuntu-latest
steps:
- uses: jpmcb/[email protected]
with:
jobs: 'lgtm'
github-token: "${{ secrets.GITHUB_TOKEN }}"

0 comments on commit 3705343

Please sign in to comment.