Repository navigation
Update ACP product links to section anchors #1996
Workflow file for this run
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 on Preview | |
| on: | |
| pull_request: | |
| types: [opened, synchronize] | |
| workflow_dispatch: | |
| inputs: | |
| BRANCH: | |
| description: "Branch to Deploy" | |
| required: true | |
| default: "main" | |
| type: "string" | |
| defaults: | |
| run: | |
| working-directory: scripts/deploy | |
| concurrency: | |
| group: preview-${{ github.event.pull_request.number || github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| deploy: | |
| name: Deploy | |
| runs-on: ubuntu-latest | |
| env: | |
| BRANCH: ${{ github.event_name == 'pull_request' && github.head_ref || github.ref_name || inputs.BRANCH }} | |
| TARGET_ENV: 'preview' | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '22' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Create .env file | |
| run: | | |
| echo "VERCEL_TOKEN=${{ secrets.VERCEL_TOKEN }}" >> .env | |
| echo "BRANCH=${{ env.BRANCH }}" >> .env | |
| echo "TARGET_ENV=${{ env.TARGET_ENV }}" >> .env | |
| - name: Cat .env file | |
| run: cat .env | |
| - name: Run Deploy Script | |
| run: npm run deploy |