✅ Next.js 14 web app (refactored from React Native)
✅ Automated deployment scripts for VPS (65.20.69.64)
✅ PDF backend (Express + Puppeteer) to fetch Karnataka land records
✅ Complete documentation for setup and maintenance
cd /Users/mrstark/Desktop/Code\ PlayGround/GeoDocs
./scripts/deploy-to-vps.shWhat happens:
- Adds VPS fingerprint to
~/.ssh/known_hosts✅ - Syncs project files to VPS via rsync ✅
- Installs Node.js, dependencies, builds app ✅
- Starts app with PM2 on port 3000 ✅
First time? You'll be asked for the root password.
Open: http://65.20.69.64:3000
# Generate key
ssh-keygen -t ed25519 -f ~/.ssh/geodocs_vps -N ""
# Copy to VPS (enter password when asked)
ssh-copy-id -i ~/.ssh/geodocs_vps.pub root@65.20.69.64
# Add to config
cat >> ~/.ssh/config << 'EOF'
Host geodocs-vps
HostName 65.20.69.64
User root
IdentityFile ~/.ssh/geodocs_vps
EOF
# Now connect without password
ssh geodocs-vps| File | Purpose |
|---|---|
| START_HERE.md (this file) | Quick start guide |
| DEPLOYMENT_QUICK_START.md | One-command deploy + troubleshooting |
| DEPLOY_CHECKLIST.md | Step-by-step checklist |
| VPS_SETUP.md | Detailed VPS setup instructions |
| README.md | Project overview and local dev |
Anytime you make changes:
./scripts/deploy-to-vps.shssh root@65.20.69.64
# or if you set up config:
ssh geodocs-vpsssh root@65.20.69.64
pm2 status
pm2 logs geodocsssh root@65.20.69.64
pm2 restart geodocsThe Documents and Village Search features need the PDF backend to work.
ssh root@65.20.69.64
cd /var/www/geodocs
# Install Puppeteer dependencies (Chromium)
apt-get update && apt-get install -y \
chromium-browser \
fonts-liberation \
libnss3 \
libatk-bridge2.0-0 \
libx11-xcb1 \
libxcomposite1 \
libxdamage1 \
libxrandr2
# Start PDF API on port 3001
pm2 start npm --name geodocs-api -- run api
pm2 save
pm2 statusNow the Get PDF button in Documents and Village Search will work.
-
Point your domain (e.g., geodocs.example.com) to 65.20.69.64
-
On VPS:
ssh root@65.20.69.64
# Install Nginx
apt-get install -y nginx certbot python3-certbot-nginx
# Create Nginx config (replace your-domain.com)
cat > /etc/nginx/sites-available/geodocs << 'EOF'
server {
listen 80;
server_name your-domain.com;
location / {
proxy_pass http://localhost:3000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
EOF
# Enable site
ln -s /etc/nginx/sites-available/geodocs /etc/nginx/sites-enabled/
nginx -t
systemctl reload nginx
# Get SSL certificate
certbot --nginx -d your-domain.com- Access via https://your-domain.com
# Test connection
ssh -v root@65.20.69.64
# If timeout, check firewall/provider settingsssh root@65.20.69.64
# Check if running
pm2 status
# Check logs
pm2 logs geodocs
# Restart
pm2 restart geodocsssh root@65.20.69.64
cd /var/www/geodocs
# Check Node version (needs 18+)
node -v
# Clean rebuild
rm -rf node_modules .next
npm ci
npm run build
pm2 restart geodocs- Home (
/) — Welcome page with feature cards - Documents (
/documents) — Village Map search with modal form - Village Search (
/search) — Dedicated search page - Map (
/map) — Placeholder for map integration - Profile (
/profile) — User profile placeholder
Data: 24,000+ Karnataka villages organized by District → Taluka → Hobli → Village
| Command | Description |
|---|---|
./scripts/deploy-to-vps.sh |
Deploy/update app |
ssh root@65.20.69.64 |
Connect to VPS |
pm2 status |
Check running apps |
pm2 logs geodocs |
View app logs |
pm2 restart geodocs |
Restart app |
pm2 monit |
Live monitoring |
Ready to deploy? Run:
./scripts/deploy-to-vps.sh🎉 Your app will be live at http://65.20.69.64:3000 in ~5 minutes!