Skip to content

Commit

Permalink
updated client/server deployment.yml file
Browse files Browse the repository at this point in the history
  • Loading branch information
Sohail-9 committed Nov 27, 2024
1 parent 8ec5aae commit 2c6b8e5
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 8 deletions.
13 changes: 10 additions & 3 deletions .github/workflows/deploy-client.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Deploy Client Production
on:
push:
paths:
- "client/**"
- "client/**" # Trigger when any file in the 'client' folder is changed

jobs:
deploy:
Expand All @@ -13,10 +13,17 @@ jobs:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: '16' # Ensure you're using the appropriate Node.js version

- name: Install Vercel CLI globally
run: npm install -g vercel

- name: Deploy to Vercel
env:
VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }}
run: |
npm install -g vercel
cd client
cd client # Navigate to the client directory
vercel --prod --token $VERCEL_TOKEN
17 changes: 12 additions & 5 deletions .github/workflows/deploy-server.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name: Deploy Server
name: Deploy Server Production

on:
push:
paths:
- "server/**"
- "server/**" # Trigger when any file in the 'server' folder is changed

jobs:
deploy:
Expand All @@ -13,10 +13,17 @@ jobs:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: '16' # Ensure you're using the appropriate Node.js version

- name: Install Vercel CLI globally
run: npm install -g vercel

- name: Deploy to Vercel
env:
VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }} # Use your Vercel token here
VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }}
run: |
npm install -g vercel
cd server # Navigate to server directory
cd server # Navigate to the server directory
vercel --prod --token $VERCEL_TOKEN

0 comments on commit 2c6b8e5

Please sign in to comment.