Add nginx deploy config and deploy script
This commit is contained in:
20
deploy/deploy.sh
Executable file
20
deploy/deploy.sh
Executable file
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/env bash
|
||||
# Deploy static site to the VPS at 82.156.24.101 over rsync+ssh.
|
||||
# Run from the project root: ./deploy/deploy.sh
|
||||
set -euo pipefail
|
||||
|
||||
SERVER="ubuntu@82.156.24.101"
|
||||
REMOTE_ROOT="/var/www/abigail"
|
||||
PROJECT_ROOT="$(cd "$(dirname "$0")/.." && pwd)"
|
||||
|
||||
echo "→ Syncing files to $SERVER:$REMOTE_ROOT"
|
||||
rsync -avz --delete \
|
||||
--include='index.html' \
|
||||
--include='abigail_*.html' \
|
||||
--exclude='*' \
|
||||
"$PROJECT_ROOT/" "$SERVER:$REMOTE_ROOT/"
|
||||
|
||||
echo "→ Reloading nginx"
|
||||
ssh "$SERVER" "sudo nginx -t && sudo systemctl reload nginx"
|
||||
|
||||
echo "✓ Live at https://82.156.24.101:8093/"
|
||||
Reference in New Issue
Block a user