Files
easystream-main/.htaccess
SamiAhmed7777 d22b3e1c0d feat: Add complete Docker deployment with web-based setup wizard
Major additions:
- Web-based setup wizard (setup.php, setup_wizard.php, setup-wizard.js)
- Production Docker configuration (docker-compose.prod.yml, .env.production)
- Database initialization SQL files (deploy/init_settings.sql)
- Template builder system with drag-and-drop UI
- Advanced features (OAuth, CDN, enhanced analytics, monetization)
- Comprehensive documentation (deployment guides, quick start, feature docs)
- Design system with accessibility and responsive layout
- Deployment automation scripts (deploy.ps1, generate-secrets.ps1)

Setup wizard allows customization of:
- Platform name and branding
- Domain configuration
- Membership tiers and pricing
- Admin credentials
- Feature toggles

Database includes 270+ tables for complete video streaming platform with
advanced features for analytics, moderation, template building, and monetization.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-26 01:42:31 -07:00

95 lines
3.6 KiB
ApacheConf

# EasyStream Docker Container URL Routing Configuration
# Optimized for Caddy + PHP-FPM container setup
RewriteEngine On
# Security Rules - Block access to sensitive directories
RewriteRule ^f_core/ - [F,L]
RewriteRule ^f_data/(?!media|uploads) - [F,L]
RewriteRule ^deploy/ - [F,L]
RewriteRule ^\.git/ - [F,L]
RewriteRule ^docker-compose\.yml$ - [F,L]
RewriteRule ^Dockerfile - [F,L]
# Container Health Check
RewriteRule ^health/?$ health_check.php [L]
# Token System Routes (Container-specific)
RewriteRule ^token[_-]purchase/?$ f_modules/m_frontend/m_donations/token_purchase.php [L,QSA]
RewriteRule ^token[_-]redemption/?$ f_modules/m_frontend/m_donations/token_redemption.php [L,QSA]
RewriteRule ^tokens/?$ f_modules/m_frontend/m_donations/token_purchase.php [L,QSA]
# Donation System Routes
RewriteRule ^donate/?$ f_modules/m_frontend/m_donations/rainforest_donation_form.php [L,QSA]
RewriteRule ^donation/?$ f_modules/m_frontend/m_donations/rainforest_donation_form.php [L,QSA]
# Main Application Routes - Route through index.php (which will use parser.php)
RewriteRule ^browse/?$ index.php [L,QSA]
RewriteRule ^videos/?$ index.php [L,QSA]
RewriteRule ^broadcasts/?$ index.php [L,QSA]
RewriteRule ^pictures/?$ index.php [L,QSA]
RewriteRule ^images/?$ index.php [L,QSA]
RewriteRule ^music/?$ index.php [L,QSA]
RewriteRule ^audios/?$ index.php [L,QSA]
RewriteRule ^documents/?$ index.php [L,QSA]
RewriteRule ^blogs/?$ index.php [L,QSA]
RewriteRule ^shorts/?$ index.php [L,QSA]
RewriteRule ^search/?$ index.php [L,QSA]
RewriteRule ^upload/?$ index.php [L,QSA]
RewriteRule ^view/([^/]+)/?$ index.php [L,QSA]
# User Account Routes - Route through index.php (which will use parser.php)
RewriteRule ^signin/?$ index.php [L,QSA]
RewriteRule ^signup/?$ index.php [L,QSA]
RewriteRule ^register/?$ index.php [L,QSA]
RewriteRule ^account/?$ index.php [L,QSA]
RewriteRule ^@([^/]+)/?$ index.php [L,QSA]
RewriteRule ^channel/([^/]+)/?$ index.php [L,QSA]
# Admin Panel Routes - Route to admin dashboard
RewriteRule ^admin/?$ admin_dashboard.php [L,QSA]
RewriteRule ^admin/([^/]+)/?$ admin_dashboard.php [L,QSA]
RewriteRule ^admin/([^/]+)/([^/]+)/?$ admin_dashboard.php [L,QSA]
# API Routes
RewriteRule ^api/(.*)$ f_modules/api/index.php?endpoint=$1 [L,QSA]
# Webhook Routes (Container-specific)
RewriteRule ^webhook/rainforest/?$ f_modules/m_frontend/m_donations/rainforest_webhook.php [L]
RewriteRule ^webhooks/(.*)$ f_modules/webhooks/$1.php [L]
# Container Media Routes (Volume mounts)
RewriteRule ^hls/(.*)$ /var/www/hls/$1 [L]
RewriteRule ^rec/(.*)$ /mnt/rec/$1 [L]
RewriteRule ^media/(.*)$ f_data/media/$1 [L]
RewriteRule ^uploads/(.*)$ f_data/uploads/$1 [L]
RewriteRule ^thumbs/(.*)$ f_data/thumbs/$1 [L]
# Static Asset Routes
RewriteRule ^css/(.*)$ f_templates/tpl_frontend/css/$1 [L]
RewriteRule ^js/(.*)$ f_scripts/fe/js/$1 [L]
RewriteRule ^img/(.*)$ f_scripts/fe/img/$1 [L]
# Legacy Support Routes
RewriteRule ^view/([^/]+)/?$ index.php?page=watch&v=$1 [L,QSA]
RewriteRule ^user/([^/]+)/?$ index.php?page=channel&user=$1 [L,QSA]
# Container-specific fallback - Route everything to index.php
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/f_modules/
RewriteCond %{REQUEST_URI} !^/admin_dashboard\.php
RewriteCond %{REQUEST_URI} !^/health_check\.php
RewriteCond %{REQUEST_URI} !^/f_data/
RewriteCond %{REQUEST_URI} !^/f_templates/
RewriteCond %{REQUEST_URI} !^/f_scripts/
RewriteRule ^(.*)$ index.php [L,QSA]
# Container PHP Configuration
php_flag display_errors Off
php_flag log_errors On
php_value max_execution_time 300
php_value memory_limit 512M
php_value upload_max_filesize 500M
php_value post_max_size 500M