diff --git a/.github/workflows/spec-validate.yaml b/.github/workflows/spec-validate.yaml index 2a990b3..c961089 100644 --- a/.github/workflows/spec-validate.yaml +++ b/.github/workflows/spec-validate.yaml @@ -1,7 +1,7 @@ name: OpenAPI spec validation action on: - pull_request_target: + pull_request: types: - opened - edited @@ -15,6 +15,6 @@ jobs: uses: actions/checkout@v4 - name: Run OpenAPI spec validation - run: | - docker run --rm -v $PWD:/spec redocly/cli lint ./service/openapi.yaml - echo "{exit_code}={$?}" >> $GITHUB_STATE \ No newline at end of file + uses: stoplightio/spectral-action@v0.8.11 + with: + file_glob: 'service/openapi.yaml' diff --git a/.spectral.yaml b/.spectral.yaml new file mode 100644 index 0000000..a8d6190 --- /dev/null +++ b/.spectral.yaml @@ -0,0 +1,2 @@ +extends: + - spectral:oas