Skip to content

Update the rest of the registry docs #7883

Update the rest of the registry docs

Update the rest of the registry docs #7883

name: pr-deploy-and-comment
concurrency:
group: pullrequest-untrusted-deploy-${{ github.event.number }}
cancel-in-progress: true
on:
pull_request_target:
branches: [ main ]
types: [ labeled, synchronize ]
jobs:
pr-deploy-and-comment:
if: ${{ contains(github.event.*.labels.*.name, 'safe to build') }}
runs-on: [self-hosted, x64, linux]
container:
image: ghcr.io/viamrobotics/canon:amd64
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.sha }}
submodules: true # fetch hugo themes
fetch-depth: 0
- name: Setup Hugo
uses: peaceiris/actions-hugo@v2
with:
hugo-version: 'latest'
extended: true
- name: Temp config
run: |
echo url_latest_version = \"https://docs-test.viam.dev/${{ github.event.number }}/public\" > config_pr.toml
echo baseURL = \"https://docs-test.viam.dev/${{ github.event.number }}/public\" >> config_pr.toml
- name: Build
run: make build-pr
- name: Authenticate on GCS
uses: google-github-actions/auth@v0
with:
credentials_json: '${{ secrets.GOOGLE_CREDENTIALS }}'
- name: 'Set up Cloud SDK'
uses: 'google-github-actions/setup-gcloud@v0'
- name: 'Use gcloud CLI'
run: 'gsutil -m rsync -R -d public gs://docs-test.viam.dev/${{ github.event.number }}/public'
- name: Comment on PR with link to rendered site
uses: marocchino/[email protected]
with:
recreate: true
message: 'You can view a rendered version of the docs from this PR at https://docs-test.viam.dev/${{ github.event.number }}/public'
GITHUB_TOKEN: ${{ secrets.PR_TOKEN }}