Using NEXT_PUBLIC_VERCEL_ENV to determine whether to reroute chat/suggest endpoints #5329
Workflow file for this run
This file contains 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 @fern-docs/local-preview-bundle | |
on: | |
workflow_dispatch: {} | |
pull_request: {} | |
push: | |
branches: [main] | |
tags: ["*"] | |
env: | |
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }} | |
TURBO_TEAM: "buildwithfern" | |
FERN_TOKEN: ${{ secrets.FERN_TOKEN }} | |
GITHUB_TOKEN: ${{ secrets.FERN_GITHUB_TOKEN }} | |
jobs: | |
dev: | |
runs-on: ubuntu-latest | |
if: github.ref == 'refs/heads/main' | |
container: | |
image: cimg/node:18.18.2 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
aws-region: us-east-1 | |
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
- name: Install | |
uses: ./.github/actions/install | |
- name: Build local preview bundle | |
run: | | |
pnpm compile | |
ENABLE_SOURCE_MAPS=true pnpm turbo --filter=@fern-docs/local-preview-bundle build | |
- name: Deploy local preview bundle | |
run: pnpm --filter=@fern-platform/cdk run deploy:dev2 | |
prod: | |
runs-on: ubuntu-latest | |
if: github.ref_type == 'tag' && startsWith(github.ref, 'refs/tags/ui@') | |
container: | |
image: cimg/node:18.18.2 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
aws-region: us-east-1 | |
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
- name: Install | |
uses: ./.github/actions/install | |
- name: Build local preview bundle | |
run: pnpm turbo --filter=@fern-docs/local-preview-bundle build | |
- name: Deploy local preview bundle | |
run: pnpm --filter=@fern-platform/cdk run deploy:prod |