Skip to content

Commit 8389763

Browse files
committed
fix: use dist/ from GitHub Actions instead of rebuilding on VPS
1 parent 73f81f2 commit 8389763

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

.github/workflows/deploy.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,22 +40,22 @@ jobs:
4040
uses: appleboy/scp-action@master
4141
with:
4242
host: ${{ secrets.VPS_HOST }}
43-
username: ${{ secrets.VPS_USERNAME }}
43+
username: deploy
4444
key: ${{ secrets.VPS_SSH_KEY }}
4545
port: ${{ secrets.VPS_PORT || 22 }}
46-
source: "dist/,package.json,pnpm-lock.yaml"
47-
target: "/home/${{ secrets.VPS_USERNAME }}/elearning-backend"
46+
source: "dist/,package.json,pnpm-lock.yaml,deploy.sh"
47+
target: "/home/deploy/elearning-backend"
4848
strip_components: 0
4949

5050
- name: Execute deployment script on VPS
5151
uses: appleboy/ssh-action@master
5252
with:
5353
host: ${{ secrets.VPS_HOST }}
54-
username: ${{ secrets.VPS_USERNAME }}
54+
username: deploy
5555
key: ${{ secrets.VPS_SSH_KEY }}
5656
port: ${{ secrets.VPS_PORT || 22 }}
5757
script: |
58-
cd /home/${{ secrets.VPS_USERNAME }}/elearning-backend
58+
cd /home/deploy/elearning-backend
5959
chmod +x deploy.sh
6060
./deploy.sh
6161

0 commit comments

Comments
 (0)