mirror of
https://github.com/thecyberlearn/quantumtaskai-caprover.git
synced 2026-08-18 07:52:55 +00:00
MAJOR CLEANUP: - Remove ALL backup files and duplicate variants (*-simple, *.backup) - Standardize requirements.txt to 11 essential dependencies (vs 24) - Clean settings.py: remove middleware/cache/Redis dependencies - Simplify Dockerfile.captain: essential features only - Replace 2 deployment guides with 1 clean DEPLOYMENT_GUIDE.md - Fix broken imports in authentication, agents, wallet modules RESULT: - One clean standard version of everything - No more confusion between simple/complex variants - Essential dependencies only - Standard Django configuration - Ready for straightforward CapRover deployment - All imports working correctly 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
4.5 KiB
4.5 KiB
CapRover Deployment Guide - Quantum Tasks AI
Overview
Step-by-step guide for deploying the Quantum Tasks AI Django application on CapRover.
Prerequisites
- CapRover installed and running on your VPS
- GitHub repository with the project
- Basic understanding of Django and CapRover
Part 1: Project Setup
Required Files
Your repository contains these CapRover-ready files:
quantumtaskai-caprover/
├── captain-definition # CapRover configuration
├── Dockerfile.captain # Production Docker setup
├── requirements.txt # Essential Python dependencies
├── .dockerignore # Docker build optimization
└── netcop_hub/settings.py # Django settings with production support
Key Features
- Database: Supports SQLite (dev), PostgreSQL (production)
- Static Files: WhiteNoise for production serving
- Environment Variables: Production-ready configuration
Part 2: CapRover Deployment
Step 1: Create New App
- Open CapRover Dashboard
- Apps → Create New App
- App Name:
quantumtaskai(or your preferred name) - Click "Create New App"
Step 2: Configure GitHub Deployment
- Go to: App → Deployment Tab
- Method: Deploy from GitHub
- Repository:
https://github.com/thecyberlearn/quantumtaskai-caprover.git - Branch:
main - Authentication: Use GitHub Personal Access Token
Step 3: Environment Variables
Go to: App Configs → Environment Variables → Bulk Edit
Essential Variables:
SECRET_KEY=your-unique-secret-key-here
DEBUG=false
ALLOWED_HOSTS=yourapp.yourdomain.com
DATABASE_URL=postgres://user:password@host:5432/database
Optional Variables:
# Email Configuration (for notifications)
EMAIL_HOST_USER=your-email@gmail.com
EMAIL_HOST_PASSWORD=your-app-password
# Stripe Configuration (for payments)
STRIPE_SECRET_KEY=sk_test_your_stripe_key
STRIPE_WEBHOOK_SECRET=whsec_your_webhook_secret
Step 4: Deploy Application
- Deployment Tab → Deploy Now
- Monitor build logs for successful completion
- Check App URL after deployment completes
Part 3: Database Setup (Optional)
If you need PostgreSQL database:
Option A: CapRover PostgreSQL
- One-Click Apps → PostgreSQL
- Create database instance
- Get connection details from app configs
- Add DATABASE_URL to your app environment variables
Option B: External Database
- Use Railway, Neon, or other PostgreSQL provider
- Get connection string
- Add to environment variables
Part 4: Custom Domain (Optional)
- App Settings → HTTP Settings
- Add your domain:
yourdomain.com - Enable HTTPS: Force HTTPS redirect
- Update DNS: Point your domain to CapRover server IP
Part 5: Post-Deployment
Create Admin User
- App → Web Terminal
- Run commands:
python manage.py migrate
python manage.py createsuperuser
Verify Deployment
- Visit your app URL
- Check admin panel:
/admin/ - Test agent marketplace:
/agents/
Troubleshooting
Build Failures
- Check logs in Deployment tab
- Verify environment variables are set
- Ensure SECRET_KEY is properly set
Runtime Issues
- Check App Logs in CapRover dashboard
- Verify DATABASE_URL format
- Check ALLOWED_HOSTS includes your domain
Database Issues
- Run migrations:
python manage.py migrate - Check database connectivity
- Verify PostgreSQL is running (if using)
Environment Variable Reference
| Variable | Required | Description |
|---|---|---|
SECRET_KEY |
Yes | Django secret key |
DEBUG |
Yes | Set to false for production |
ALLOWED_HOSTS |
Yes | Your domain name |
DATABASE_URL |
Optional | PostgreSQL connection string |
EMAIL_HOST_USER |
Optional | SMTP email username |
EMAIL_HOST_PASSWORD |
Optional | SMTP email password |
STRIPE_SECRET_KEY |
Optional | Stripe API key |
Success Checklist
- App builds successfully in CapRover
- Environment variables configured
- Database migrations completed
- Admin user created
- App accessible via URL
- Static files loading correctly
- Agent marketplace functional
Your Quantum Tasks AI application should now be live and ready to use!
Support
For issues with:
- CapRover deployment: Check CapRover documentation
- Django configuration: Review
netcop_hub/settings.py - Agent system: See
agents/directory structure