Deploy Site #1268
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 Site | |
| on: | |
| push: | |
| branches: [ main ] | |
| # twix dispatches this when published extensions change, so the site | |
| # picks up directory content without waiting for a push or the nightly | |
| # build. Dispatching builds current main; re-running an old run would | |
| # rebuild that run's commit. | |
| workflow_dispatch: | |
| env: | |
| SSH_USER: "${{ vars.DEPLOY_SSH_USER }}" | |
| SSH_HOST: "${{ secrets.DEPLOY_SSH_HOST }}" | |
| PILOTMOON_API_KEY: "${{ secrets.PILOTMOON_API_KEY }}" | |
| jobs: | |
| build: | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - uses: actions/checkout@v7.0.1 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v7.0.0 | |
| with: | |
| node-version-file: '.node-version' | |
| cache: npm | |
| - name: Install dependencies | |
| run: npm ci --prefer-offline --no-audit --no-fund | |
| - name: Build | |
| run: npm run docs:build-ci | |
| - name: Install SSH Key | |
| uses: shimataro/ssh-key-action@v2.8.1 | |
| with: | |
| key: ${{ secrets.DEPLOY_SSH_PRIVATE_KEY }} | |
| known_hosts: ${{ secrets.DEPLOY_SSH_KNOWN_HOSTS }} | |
| - name: Deploy | |
| run: ./deploy | |