OPS [DOCS] Add DreamHost deploy pipeline for Dyno docs at /docs 🦕🚀 #1
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 Site to DreamHost | |
| on: | |
| push: | |
| branches: [ master ] | |
| jobs: | |
| build-and-deploy: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repo | |
| uses: actions/checkout@v4 | |
| - name: Set up Node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: 'npm' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Build docs | |
| run: npm run build | |
| # Optional: sanity check build output | |
| - name: List build output | |
| run: ls -R build | |
| - name: Deploy via SFTP | |
| uses: wlixcc/SFTP-Deploy-Action@v1.2.4 | |
| with: | |
| server: ${{ secrets.SFTP_HOST }} | |
| username: ${{ secrets.SFTP_USER }} | |
| password: ${{ secrets.SFTP_PASS }} | |
| port: 22 | |
| # Upload the *contents* of build to the docs web root | |
| local_path: './build/*' | |
| remote_path: ${{ secrets.DOCS_SFTP_PATH }} | |
| delete_remote_files: false |