Skip to content

Commit

Permalink
Update main.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
AbolfazlGhaderi authored Dec 8, 2024
1 parent d661614 commit d086942
Showing 1 changed file with 14 additions and 12 deletions.
26 changes: 14 additions & 12 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,17 @@ jobs:
- name: Build Project
run: npm run build

- name: Deploy to Server
env:
SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
run: |
ssh-add - <<< "$SSH_PRIVATE_KEY"
ssh -o StrictHostKeyChecking=no [email protected] << 'EOF'
cd /home/project/test-nest-snapp/SnappFood-Nestjs
git pull
npm install
npm run build
npm run start:dev
EOF
- name: Deploy to Server
env:
SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
run: |
eval "$(ssh-agent -s)"
ssh-add - <<< "$SSH_PRIVATE_KEY"
ssh -o StrictHostKeyChecking=no [email protected] << 'EOF'
cd /home/project/test-nest-snapp/SnappFood-Nestjs
git pull
npm install
npm run build
npm run start:dev
EOF

0 comments on commit d086942

Please sign in to comment.