mirror of https://github.com/buster-so/buster.git
31 lines
939 B
YAML
31 lines
939 B
YAML
name: Deploy Trigger.dev Tasks
|
|
|
|
on:
|
|
push:
|
|
branches: [main, staging]
|
|
|
|
# Only one deployment per environment at a time
|
|
concurrency:
|
|
group: trigger-deploy-${{ github.ref }}
|
|
cancel-in-progress: false # Never cancel deployments
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: blacksmith-4vcpu-ubuntu-2404
|
|
environment: ${{ github.ref_name }}
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup Node Environment
|
|
uses: ./.github/actions/setup-node-env
|
|
with:
|
|
install-filter: "@buster-app/trigger..."
|
|
cache-key: trigger-deployment
|
|
|
|
- name: 🚀 Deploy to ${{ github.ref_name == 'main' && 'Production' || 'Staging' }}
|
|
env:
|
|
TRIGGER_ACCESS_TOKEN: ${{ secrets.TRIGGER_ACCESS_TOKEN }}
|
|
run: |
|
|
cd apps/trigger
|
|
pnpm dlx trigger.dev@latest deploy --env ${{ github.ref_name == 'main' && 'production' || 'staging' }} |