balena os and device type support policies #2837
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: Flowzone | |
on: | |
pull_request: | |
types: [opened, synchronize, closed] | |
branches: [main, master] | |
# allow external contributions to use secrets within trusted code | |
pull_request_target: | |
types: [opened, synchronize, closed] | |
branches: [main, master] | |
jobs: | |
flowzone: | |
name: Flowzone | |
uses: product-os/flowzone/.github/workflows/flowzone.yml@master | |
# prevent duplicate workflow executions for pull_request and pull_request_target | |
if: | | |
( | |
github.event.pull_request.head.repo.full_name == github.repository && | |
github.event_name == 'pull_request' | |
) || ( | |
github.event.pull_request.head.repo.full_name != github.repository && | |
github.event_name == 'pull_request_target' | |
) | |
secrets: inherit | |
with: | |
cloudflare_website: "balenacloud-docs" | |
docusaurus_website: false | |
link-checker: | |
name: Check links in pull request | |
runs-on: ubuntu-latest | |
needs: flowzone | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
persist-credentials: false | |
# fetch external files && building the docs | |
- name: Build the docs | |
uses: actions/setup-node@8f152de45cc393bb48ce5d89d36b731f54556e65 | |
with: | |
node-version: 18 | |
- run: npm run deploy-docs | |
- name: Restore lychee cache | |
id: restore-cache | |
if: | | |
github.event_name == 'pull_request' || github.event_name == 'pull_request_target' | |
uses: actions/cache/restore@v3 | |
with: | |
path: .lycheecache | |
key: cache-lychee-${{ github.sha }} | |
restore-keys: cache-lychee- | |
# Run link checker on the generated HTML | |
- name: Link Checker | |
id: lychee | |
uses: lycheeverse/lychee-action@2b973e86fc7b1f6b36a93795fe2c9c6ae1118621 # for v1.10.0 | |
env: | |
DEPLOYMENT_URL: ${{ needs.flowzone.outputs.cloudflare_deployment_url || 'https://docs.balena.io' }} | |
with: | |
args: > | |
--base ${{ env.DEPLOYMENT_URL }} | |
--config ./lychee.toml | |
"build/**/*" "tools/fetch-external.sh" | |
token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Save lychee cache | |
uses: actions/cache/save@v3 | |
if: always() | |
with: | |
path: .lycheecache | |
key: ${{ steps.restore-cache.outputs.cache-primary-key }} |