summaryrefslogtreecommitdiff
path: root/.github/workflows
diff options
context:
space:
mode:
authorYuriy Andamasov <yuriy@vyos.io>2026-05-10 15:42:44 +0300
committerYuriy Andamasov <yuriy@vyos.io>2026-05-10 15:42:44 +0300
commit1bf386e2ce6e4039f9adbef868ef54758e4204c0 (patch)
tree1d805b4c748e12c084e63356015016ee513008f8 /.github/workflows
parent4a1d027c39a0816fd0690ee612987f066f5d3651 (diff)
downloadvyos-documentation-1bf386e2ce6e4039f9adbef868ef54758e4204c0.tar.gz
vyos-documentation-1bf386e2ce6e4039f9adbef868ef54758e4204c0.zip
ci: inline doc lint workflow, drop vyos/.github cross-repo dependency
The reusable lint-doc workflow at vyos/.github checks out vyos/.github on the consumer's PR base.ref to source doc-linter.py — designed for per-release-train linter rules. With this repo's default renamed current → rolling and vyos/.github still on current, the checkout errors with "fetch +refs/heads/rolling*: exit code 1". Rather than chase branch parity across repos, move the linter where it belongs: doc-linter.py is doc-specific and only consumed here. Inlining removes the cross-repo coupling permanently and unblocks any future branch renames in this repo without touching vyos/.github. - scripts/doc-linter.py: copied byte-for-byte from vyos/.github@current:.github/doc-linter.py (sha 3dc7c2fc16242e62b0ea7107f767577e999ca417 — identical across all four release-train branches in vyos/.github, so no behavioral change). - .github/workflows/lint-doc.yml: replaces `uses: vyos/.github/.github/workflows/lint-doc.yml@current` with the inlined steps. Same actions (bullfrogsec/bullfrog, trilom/file-changes-action, setup-python) and the same final invocation, just sourcing the script from this repo. Adds explicit minimal permissions (contents/pull-requests read) and passes the file list via env var to follow the workflow- injection guidance. Follow-up: vyos/.github still hosts the now-orphaned doc-linter.py and its reusable workflow — separate cleanup PR can delete them once any other consumers migrate (none observed today; this repo was the only caller). 🤖 Generated by [robots](https://vyos.io)
Diffstat (limited to '.github/workflows')
-rw-r--r--.github/workflows/lint-doc.yml34
1 files changed, 29 insertions, 5 deletions
diff --git a/.github/workflows/lint-doc.yml b/.github/workflows/lint-doc.yml
index b5ba4688..d7f25f38 100644
--- a/.github/workflows/lint-doc.yml
+++ b/.github/workflows/lint-doc.yml
@@ -2,9 +2,33 @@ name: Lint Doc
on:
pull_request:
+permissions:
+ contents: read
+ pull-requests: read
+
jobs:
- lint-doc:
- uses: vyos/.github/.github/workflows/lint-doc.yml@current
- secrets: inherit
-
-
+ doc-lint:
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v6
+
+ - name: Bullfrog Secure Runner
+ continue-on-error: true
+ uses: bullfrogsec/bullfrog@v0.8.4
+ with:
+ egress-policy: audit
+
+ - name: Get File Changes
+ id: file_changes
+ uses: trilom/file-changes-action@v1.2.4
+
+ - name: Set up Python
+ uses: actions/setup-python@v6
+ with:
+ python-version: '3.x'
+
+ - name: run doc linter
+ env:
+ FILES_MODIFIED: ${{ steps.file_changes.outputs.files_modified }}
+ run: python scripts/doc-linter.py "$FILES_MODIFIED"