Created
December 9, 2021 15:43
-
-
Save koozz/8d02d8616517577002a53d9a6ac289d4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: PR Triage | |
on: [pull_request] | |
jobs: | |
size-label: | |
name: Size label | |
runs-on: ubuntu-latest | |
steps: | |
- uses: codelytv/pr-size-labeler@v1 | |
with: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
custom-labels: | |
name: Custom labels | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/labeler@v3 | |
with: | |
configuration-path: .github/labeler.yml | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
sync-labels: true | |
yamllint: | |
name: YAML lint | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out code | |
uses: actions/checkout@v2 | |
- name: Lint YAML | |
uses: koozz/yamllint-action@1.0.0 | |
policy-check: | |
name: Policy check | |
needs: yamllint | |
runs-on: ubuntu-latest | |
container: openpolicyagent/conftest:v0.27.0 | |
steps: | |
- name: Code checkout | |
uses: actions/checkout@v2 | |
- name: Validate persons | |
run: conftest test persons/*.yml -n person -o github -p .github/policies | |
- name: Validate roles | |
run: conftest test roles/*.yml -n role -o github -p .github/policies | |
- name: Validate teams | |
run: conftest test teams/*.yml -n team -o github -p .github/policies |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment