Samad14 commited on
Commit
dd3740f
·
1 Parent(s): f001412

fix: scope Vercel CLI to team owning bio-nexus project; set NEXT_PUBLIC_API_URL in CI; make redundant Render hook non-fatal

Browse files
Files changed (1) hide show
  1. .github/workflows/deploy.yml +7 -1
.github/workflows/deploy.yml CHANGED
@@ -8,6 +8,8 @@ jobs:
8
  deploy-backend:
9
  name: Deploy Backend to Render
10
  runs-on: ubuntu-latest
 
 
11
  steps:
12
  - name: Trigger Render deploy
13
  run: |
@@ -16,7 +18,11 @@ jobs:
16
  deploy-frontend:
17
  name: Deploy Frontend to Vercel
18
  runs-on: ubuntu-latest
 
 
19
  steps:
20
  - uses: actions/checkout@v4
 
 
21
  - name: Deploy to Vercel
22
- run: npx vercel --token "${{ secrets.VERCEL_TOKEN }}" --prod --cwd bioai-platform/frontend --yes
 
8
  deploy-backend:
9
  name: Deploy Backend to Render
10
  runs-on: ubuntu-latest
11
+ # Render auto-deploys via Git on push, so a missing deploy-hook secret is non-fatal.
12
+ continue-on-error: true
13
  steps:
14
  - name: Trigger Render deploy
15
  run: |
 
18
  deploy-frontend:
19
  name: Deploy Frontend to Vercel
20
  runs-on: ubuntu-latest
21
+ env:
22
+ VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }}
23
  steps:
24
  - uses: actions/checkout@v4
25
+ - name: Ensure backend API URL is set
26
+ run: npx vercel env add NEXT_PUBLIC_API_URL production https://bio-nexus-api.onrender.com --scope team_y6MYl4hpatRBHMHSwAzCzQ5f --cwd bioai-platform/frontend --token "$VERCEL_TOKEN" || true
27
  - name: Deploy to Vercel
28
+ run: npx vercel --token "$VERCEL_TOKEN" --scope team_y6MYl4hpatRBHMHSwAzCzQ5f --prod --cwd bioai-platform/frontend --yes