name: docs-check on: push: tags: - v* branches: - master - release-* pull_request: branches: - master - release-* # cancel the in-progress workflow when PR is refreshed. concurrency: group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }} cancel-in-progress: true permissions: contents: read jobs: docs-check: name: docs-check runs-on: ubuntu-22.04 steps: - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 with: fetch-depth: 0 - uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0 with: go-version: "1.26" - uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0 with: python-version: 3.9 - uses: DavidAnson/markdownlint-cli2-action@6bf21b07787794f89a243495939cd651942aeabe # v24.1.0 with: globs: | Documentation/**/*.md !Documentation/Helm-Charts - name: Check docs run: | make gen.docs tests/scripts/validate_modified_files.sh docs - name: Install mkdocs and dependencies run: cd build/release/ && make deps.docs - name: Check documentation for CRDs run: | make generate-docs-crds DIFF_ON_DOCS=$(git diff --ignore-matching-lines='on git commit') if [ -n "$DIFF_ON_DOCS" ]; then echo "Please run 'make generate-docs-crds' locally, commit the updated crds docs, and push the change" fi git diff --ignore-matching-lines='on git commit' --exit-code - name: Build documentation using mkdocs run: make docs-build