添加一键部署脚本:deploy.sh (bash) 和 deploy.ps1 (PowerShell)
This commit is contained in:
+10
@@ -0,0 +1,10 @@
|
||||
$VPS = "root@38.54.27.70"
|
||||
$PROJECT = "/root/PolyWeather"
|
||||
|
||||
Write-Host "🚀 Deploying to $VPS..." -ForegroundColor Cyan
|
||||
|
||||
ssh $VPS "cd $PROJECT && git pull && docker compose up -d --build"
|
||||
|
||||
Write-Host "✅ Deploy complete. Checking health..." -ForegroundColor Green
|
||||
Start-Sleep 8
|
||||
ssh $VPS "curl -s http://localhost:8000/healthz"
|
||||
@@ -0,0 +1,12 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
VPS="root@38.54.27.70"
|
||||
PROJECT="/root/PolyWeather"
|
||||
|
||||
echo "🚀 Deploying to $VPS..."
|
||||
|
||||
ssh "$VPS" "cd $PROJECT && git pull && docker compose up -d --build"
|
||||
|
||||
echo "✅ Deploy complete. Checking health..."
|
||||
sleep 8
|
||||
ssh "$VPS" "curl -s http://localhost:8000/healthz"
|
||||
Reference in New Issue
Block a user