-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (30 loc) · 812 Bytes
/
deploy.yml
File metadata and controls
37 lines (30 loc) · 812 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: Deploy to VPS
on:
push:
branches:
- main
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install Bun
uses: oven-sh/setup-bun@v2
- name: Install dependencies
run: bun ci
- name: Create env file
run: |
echo "${{ secrets.ENV_FILE }}" > .env
- name: Build
run: bun run build
- name: Deploy to VPS
uses: burnett01/rsync-deployments@7.0.2
with:
switches: -avzr --delete
path: dist/
remote_path: ${{ secrets.TARGET_DIR }}
remote_host: ${{ secrets.HOST }}
remote_port: ${{ secrets.PORT }}
remote_user: ${{ secrets.USERNAME }}
remote_key: ${{ secrets.SSH_KEY }}