Pre-Deployment Checklist
Use this comprehensive checklist to verify your production deployment.Django Configuration
DEBUG Disabled
Secure SECRET_KEY
- Minimum 50 characters (config/checks.py:17)
- Unique per environment
- Never use default value
- Never commit to version control
ALLOWED_HOSTS Configured
Admin URL Changed
/admin/ to prevent automated attacks:https://yourdomain.com/secret-admin-path/SSL/TLS Security
SSL Certificate Installed
HTTPS Redirect Enabled
HSTS Configured
Secure Cookies
Database Security
Strong Database Password
- Minimum 16 characters
- Mix of letters, numbers, symbols
- Unique per environment
Database Connectivity
Database Backups Configured
Redis Configuration
Redis Connectivity
Redis Password (Optional but Recommended)
Storage Configuration
Storage Credentials Configured
Static Files Collected
CORS Configured (R2 Only)
Email Configuration
SendGrid API Key Configured
Sender Domain Verified
- SendGrid > Settings > Sender Authentication
- Verify domain is authenticated
- DNS records are configured
Test Email Delivery
Error Tracking
Sentry DSN Configured
Test Sentry Integration
Security Headers
Content Security Policy
Verify Security Headers
Strict-Transport-SecurityX-Frame-Options: DENYX-Content-Type-Options: nosniffReferrer-Policy: strict-origin-when-cross-originContent-Security-Policy
Test with Security Headers Analyzer
Firewall and Network
Firewall Configured
Fail2ban Enabled (Bare Metal)
SSH Security
Service Health
All Services Running
Health Endpoints
Admin Access
Django Deployment Checks
Run Django Checks
- ✓ DEBUG disabled (checks.py:20)
- ✓ SECRET_KEY secure (checks.py:40)
- ✓ Required environment variables (checks.py:83)
- ✓ Database connectivity (checks.py:127)
- ✓ Redis connectivity (checks.py:151)
- ✓ Storage credentials (checks.py:268)
- ✓ ALLOWED_HOSTS configured (checks.py:300)
- ✓ SSL/HTTPS settings (checks.py:334)
Address Warnings
- Missing SENTRY_DSN (recommended)
- ALLOWED_HOSTS contains wildcard
- Missing storage credentials
Production Deployment Checklist
Print and complete this checklist:Django Configuration
-
DEBUG=Falseset - Unique
SECRET_KEYgenerated (50+ characters) -
ALLOWED_HOSTSconfigured (no wildcards) - Admin URL changed from default
-
python manage.py check --deploypasses
Security
- SSL certificate installed and valid
- HTTPS redirect enabled (
SECURE_SSL_REDIRECT=True) - HSTS configured
- Secure cookies configured
- Content Security Policy enabled
- Security headers verified
- Firewall configured (UFW or cloud firewall)
- Fail2ban enabled (bare metal)
- SSH hardened (no root, key-based auth)
Database
- Strong database password set
- Database connectivity verified
- Database backups configured
- Backup restoration tested
Redis
- Redis connectivity verified
- Redis password set (recommended)
Storage
- Storage backend configured (S3/R2)
- Storage credentials validated
-
collectstaticruns successfully - Static files accessible via CDN/bucket URL
- CORS configured (R2 only)
- SendGrid API key configured
- Sender domain verified in SendGrid
- Test email sent successfully
Monitoring
- Sentry DSN configured
- Sentry integration tested
- Error alerts configured in Sentry
Services
- All services running and enabled
- Health endpoints responding
- Admin panel accessible
- Logs are being written
- Log rotation configured
Performance
- Gunicorn workers configured appropriately
- Redis caching enabled
- Compression enabled
- Static files served from CDN
Documentation
- Environment variables documented
- Deployment process documented
- Recovery procedures documented
- Team has access to credentials (securely)
Post-Deployment Monitoring
After deployment, monitor for:First 24 Hours
Check Error Rates
Check Error Rates
- Check error frequency
- Review stack traces
- Verify no critical errors
Monitor Performance
Monitor Performance
Review Logs
Review Logs
Verify Backups
Verify Backups
First Week
- Monitor disk space usage
- Review user registration and activity
- Check email delivery success rate
- Verify SSL certificate auto-renewal is configured
- Review Sentry performance metrics
- Test database restore procedure
Ongoing
- Weekly log reviews
- Monthly security updates
- Quarterly credential rotation
- Regular backup restoration tests
- Performance monitoring and optimization
Troubleshooting Checklist Failures
Django Checks Failing
Django Checks Failing
Health Endpoints Not Responding
Health Endpoints Not Responding
Static Files 404
Static Files 404
Database Connection Errors
Database Connection Errors
Final Verification
Before announcing your deployment:Complete User Journey
- Visit homepage via HTTPS
- Register new account
- Verify email received
- Log in
- Create an item
- Upload a photo
- View collection
- Test search/filter
- Log out
Security Scan
- SSL Labs - A or A+ grade
- SecurityHeaders.com - A or A+ grade
- Mozilla Observatory - A or A+ grade
Load Test (Optional)