mirror of https://github.com/hashicorp/boundary
Add check to ensure milestone (#2747)
* Add check to ensure milestone Stolen from https://github.com/hashicorp/vault/pull/18406 * Update .github/workflows/milestone-checker.yml Co-authored-by: Johan Brandhorst-Satzkorn <johan.brandhorst@gmail.com> * Pin grafana github actions ref Co-authored-by: Johan Brandhorst-Satzkorn <johan.brandhorst@gmail.com>pull/2752/head
parent
d5fed10918
commit
ee7bf3cde6
@ -0,0 +1,9 @@
|
||||
[
|
||||
{
|
||||
"type": "check-milestone",
|
||||
"title": "Milestone Check",
|
||||
"success": "Milestone set",
|
||||
"failure": "Milestone not set"
|
||||
}
|
||||
]
|
||||
|
||||
@ -0,0 +1,33 @@
|
||||
# This workflow checks that there is either a 'pr/no-milestone' label applied
|
||||
# to a PR or there is a milestone associated with a PR
|
||||
|
||||
name: Check Milestone
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
types: [opened, synchronize, labeled, unlabeled]
|
||||
# Runs on PRs to main and release branches
|
||||
branches:
|
||||
- main
|
||||
- release/**
|
||||
|
||||
jobs:
|
||||
# checks that a milestone entry is present for a PR
|
||||
milestone-check:
|
||||
# If there is a `pr/no-milestone` label we ignore this check
|
||||
if: "!contains(github.event.pull_request.labels.*.name, 'pr/no-milestone')"
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: "grafana/grafana-github-actions"
|
||||
path: ./actions
|
||||
ref: be89ad434792280ebaa4d982ac72ba548b6f7095
|
||||
- name: Install Actions
|
||||
run: npm install --production --prefix ./actions
|
||||
- name: Run PR Checks
|
||||
uses: ./actions/pr-checks
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
configPath: configs/milestone-check
|
||||
Loading…
Reference in new issue