Deploy Docs #24
This file contains hidden or 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: Deploy Docs | |
| on: | |
| workflow_dispatch: | |
| jobs: | |
| deploy: | |
| name: Build & Deploy | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v4 | |
| with: | |
| version: 10.29.2 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 24.14.1 | |
| cache: pnpm | |
| cache-dependency-path: | | |
| docs/website/pnpm-lock.yaml | |
| integrations/clipper/pnpm-lock.yaml | |
| - name: Install dependencies | |
| run: | | |
| pnpm --dir docs/website install | |
| pnpm --dir integrations/clipper install | |
| - name: Build clipper downloads | |
| run: | | |
| pnpm --dir integrations/clipper package | |
| mkdir -p docs/website/public/clipper/downloads | |
| cp integrations/clipper/builds/*-chrome.zip docs/website/public/clipper/downloads/clipper-chrome.zip | |
| cp integrations/clipper/builds/*-firefox.zip docs/website/public/clipper/downloads/clipper-firefox.zip | |
| cp integrations/clipper/builds/*-safari.zip docs/website/public/clipper/downloads/clipper-safari.zip | |
| - name: Build docs | |
| run: pnpm docs:build | |
| env: | |
| VITE_GA: ${{ secrets.VITE_GA }} | |
| - name: Deploy to server | |
| uses: burnett01/rsync-deployments@7.0.2 | |
| with: | |
| switches: -rlptzv --delete | |
| path: docs/website/.vitepress/dist/ | |
| remote_path: /var/www/masscode.io/public/ | |
| remote_host: ${{ secrets.DEPLOY_HOST }} | |
| remote_user: ${{ secrets.DEPLOY_USER }} | |
| remote_key: ${{ secrets.DEPLOY_SSH_KEY }} |