2.7 KiB
2.7 KiB
⚡ Quick Start Guide - Hosting Platform
For detailed information, see DEPLOYMENT.md
🎯 Most Common Tasks
1. Deploy Latest Code to Production
# From local machine
cd /Users/oguzozturk/AgumentProje/HostingProjesi/MusteriPanel
git add -A
git commit -m "Your message"
git push
# On server
ssh -i ~/.ssh/id_rsa root@176.96.129.77
cd /opt/hosting-platform
git fetch origin && git reset --hard origin/main
supervisorctl restart hosting-backend
2. Check if Everything is Running
ssh -i ~/.ssh/id_rsa root@176.96.129.77
# Check services
supervisorctl status
# Check health
curl http://localhost:5000/health
# Check logs
tail -f /var/log/hosting-backend.log
3. Run Database Migration
ssh -i ~/.ssh/id_rsa root@176.96.129.77
cd /opt/hosting-platform
sudo -u postgres psql -d hosting -f backend/migrations/YOUR_FILE.sql
supervisorctl restart hosting-backend
4. View Logs
ssh -i ~/.ssh/id_rsa root@176.96.129.77
# Backend logs
tail -f /var/log/hosting-backend.log
tail -f /var/log/admin-backend.log
# Nginx logs
tail -f /var/log/nginx/error.log
5. Restart Services
ssh -i ~/.ssh/id_rsa root@176.96.129.77
# Customer backend
supervisorctl restart hosting-backend
# Admin backend (manual)
pkill -f 'admin-panel/backend'
cd /opt/admin-panel/backend && source venv/bin/activate
nohup python -m app.main > /var/log/admin-backend.log 2>&1 &
🔗 Quick Links
- Customer Panel: https://panel.argeict.net
- Admin Panel: https://admin.argeict.net
- Gitea: https://gitea.argeict.net
- Server IP: 176.96.129.77
📁 Important Paths
- Project:
/opt/hosting-platform/ - Admin Panel:
/opt/admin-panel/ - Logs:
/var/log/hosting-*.log - Nginx Config:
/etc/nginx/sites-available/ - Supervisor Config:
/etc/supervisor/conf.d/
🗄️ Database Quick Access
# List databases
sudo -u postgres psql -l
# Connect to main database
sudo -u postgres psql -d hosting
# Quick queries
sudo -u postgres psql -d hosting -c "SELECT * FROM customers;"
sudo -u postgres psql -d hosting -c "SELECT * FROM cloudflare_accounts;"
🆘 Emergency Commands
# If backend is stuck
supervisorctl restart hosting-backend
# If git pull fails
cd /opt/hosting-platform
git fetch origin && git reset --hard origin/main
# If database is locked
sudo systemctl restart postgresql
# If Nginx has issues
nginx -t && systemctl restart nginx
📚 Read This First
Before any deployment or debugging:
- Read DEPLOYMENT.md for complete details
- Check current running processes
- Review recent logs
- Test locally before deploying
Last Updated: 2026-01-12