feat: enterprise-grade Docker setup for Dokploy deployment
- Add multi-stage Dockerfile (node-builder, composer-builder, production) - Add Nginx config with WebSocket proxy at /_ws path - Add PHP-FPM pool config, php.ini with OPcache tuning - Add Supervisord managing 7 processes: php-fpm, nginx, horizon, scheduler, reverb, pulse-check, pulse-work - Add entrypoint.sh with auto-migration, config caching, storage setup - Add .dockerignore and .env.production.example - Install laravel/horizon for production queue management and dashboard - Install laravel/pulse for production monitoring with Reverb integration - Configure TrustProxies middleware for HTTPS behind Traefik - Add horizon:snapshot to scheduler - Add VITE_REVERB_PATH for WebSocket path routing through Nginx
This commit is contained in:
64
.env.production.example
Normal file
64
.env.production.example
Normal file
@@ -0,0 +1,64 @@
|
||||
APP_NAME=iMail
|
||||
APP_ENV=production
|
||||
APP_KEY=
|
||||
APP_DEBUG=false
|
||||
APP_URL=https://your-domain.com
|
||||
|
||||
LOG_CHANNEL=stderr
|
||||
LOG_LEVEL=info
|
||||
|
||||
# Database (MariaDB via Dokploy/External)
|
||||
DB_CONNECTION=mariadb
|
||||
DB_HOST=mariadb-host
|
||||
DB_PORT=3306
|
||||
DB_DATABASE=imail
|
||||
DB_USERNAME=root
|
||||
DB_PASSWORD=
|
||||
|
||||
# MongoDB (via Dokploy/External)
|
||||
MONGODB_URI=mongodb://mongodb-host:27017
|
||||
|
||||
# Redis (via Dokploy/External)
|
||||
REDIS_CLIENT=phpredis # Required for Laravel Pulse ingest
|
||||
REDIS_HOST=redis-host
|
||||
REDIS_PASSWORD=null
|
||||
REDIS_PORT=6379
|
||||
|
||||
CACHE_STORE=redis
|
||||
QUEUE_CONNECTION=redis
|
||||
SESSION_DRIVER=redis
|
||||
SESSION_LIFETIME=120
|
||||
SESSION_ENCRYPT=false
|
||||
SESSION_PATH=/
|
||||
SESSION_DOMAIN=null
|
||||
|
||||
BROADCAST_CONNECTION=reverb
|
||||
|
||||
FILESYSTEM_DISK=s3
|
||||
|
||||
# S3 Compatible Storage (RustFS via Dokploy/External)
|
||||
AWS_ACCESS_KEY_ID=
|
||||
AWS_SECRET_ACCESS_KEY=
|
||||
AWS_DEFAULT_REGION=us-east-1
|
||||
AWS_BUCKET=imail
|
||||
AWS_USE_PATH_STYLE_ENDPOINT=true
|
||||
AWS_ENDPOINT=http://rustfs-host:9000
|
||||
|
||||
# Reverb Configuration
|
||||
REVERB_APP_ID=
|
||||
REVERB_APP_KEY=
|
||||
REVERB_APP_SECRET=
|
||||
REVERB_HOST="your-domain.com"
|
||||
REVERB_PORT=443
|
||||
REVERB_SCHEME=https
|
||||
|
||||
# Pulse Configuration
|
||||
PULSE_INGEST_DRIVER=redis
|
||||
PULSE_REDIS_CONNECTION=default
|
||||
|
||||
VITE_APP_NAME="${APP_NAME}"
|
||||
VITE_REVERB_APP_KEY="${REVERB_APP_KEY}"
|
||||
VITE_REVERB_HOST="${REVERB_HOST}"
|
||||
VITE_REVERB_PORT="${REVERB_PORT}"
|
||||
VITE_REVERB_SCHEME="${REVERB_SCHEME}"
|
||||
VITE_REVERB_PATH="/_ws"
|
||||
Reference in New Issue
Block a user