File tree Expand file tree Collapse file tree 2 files changed +39
-102
lines changed
Expand file tree Collapse file tree 2 files changed +39
-102
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ name : Deploy Miguer API
2+
3+ on :
4+ push :
5+ branches :
6+ - main
7+
8+ jobs :
9+ deploy :
10+ name : Build and Deploy to VPS
11+ runs-on : ubuntu-latest
12+
13+ steps :
14+ - name : Checkout repo
15+ uses : actions/checkout@v3
16+
17+ - name : Install Rust
18+ uses : dtolnay/rust-toolchain@stable
19+
20+ - name : Build release
21+ run : cargo build --release
22+
23+ - name : Copy binary to VPS
24+ uses : appleboy/scp-action@v0.1.4
25+ with :
26+ host : ${{ secrets.VPS_HOST }}
27+ username : ${{ secrets.VPS_USER }}
28+ key : ${{ secrets.VPS_SSH_KEY }}
29+ source : target/release/miguer_api-cli
30+ target : /home/locoapp/miguer-api/
31+
32+ - name : Restart service via SSH
33+ uses : appleboy/ssh-action@v1.0.0
34+ with :
35+ host : ${{ secrets.VPS_HOST }}
36+ username : ${{ secrets.VPS_USER }}
37+ key : ${{ secrets.VPS_SSH_KEY }}
38+ script : |
39+ sudo systemctl restart miguer-api
You can’t perform that action at this time.
0 commit comments