feat: sync scripts, scraper, and sql tools from server

This commit is contained in:
Hamza-Ayed
2026-08-16 13:19:10 +03:00
parent 32865e78df
commit 3136a2b7aa
14 changed files with 28844 additions and 0 deletions
+20
View File
@@ -0,0 +1,20 @@
#!/bin/bash
# Download Existing Syria Data from Server to Mac
# To be run on the Mac terminal
SERVER_IP="188.68.36.205"
SERVER_USER="hamzadoctor"
REMOTE_PATH="/home/hamzadoctor/app"
KEY_PATH="/Users/hamzaaleghwairyeen/.ssh/doctory-key"
echo "🌍 Connecting to server to dump existing Syria landmarks..."
# 1. Generate dump on server
ssh -i "$KEY_PATH" "$SERVER_USER@$SERVER_IP" "docker exec -t map-db pg_dump -U mapuser -d mapdb -t places_syria --data-only --inserts > $REMOTE_PATH/existing_syria_data.sql"
# 2. Download the dump to local Mac
echo "📥 Downloading dump to Mac..."
rsync -avz -e "ssh -i $KEY_PATH" "$SERVER_USER@$SERVER_IP:$REMOTE_PATH/existing_syria_data.sql" infrastructure/docker/postgis/
echo "✅ Download complete: infrastructure/docker/postgis/existing_syria_data.sql"
echo "Now run ./infrastructure/scripts/local_db_prep.sh to merge."