Pull Request Merged
PR #19 merged: feat: improve provisioning experience with better defaults
Summary
This PR addresses several issues to improve the provisioning experience:
- #11 - Fix confusing webhook UX by using
pause()instead of Yes/No prompt - #12 - Configure TrustProxies middleware in
bootstrap/app.phpduring install - #14 - Auto-generate Reverb credentials if not present locally, set
BROADCAST_CONNECTION=reverb - #15 - Enable health checks by default with
/uppath (Laravel 11+ default) - #16 - Add
LOG_STACK=dailyandLOG_DAILY_MAX_FILES=7for better log management
Changes
ProvisionCommand.php
-
Webhook prompt UX - Changed from confusing
confirm('Have you set up the webhook?')to simplepause('Press ENTER once you have set up the webhook...')matching the deploy key pattern -
Broadcasting/Reverb - Now auto-generates
REVERB_APP_ID,REVERB_APP_KEY,REVERB_APP_SECRETif not present in local.env, and always sets production-appropriate values forREVERB_HOST,REVERB_PORT,REVERB_SCHEME -
Health Checks - Added health check configuration to application creation payload:
health_check_enabled: truehealth_check_path: '/up'health_check_method: 'GET'health_check_return_code: 200
-
Log Management - Added sensible defaults to prevent runaway log files:
LOG_STACK=dailyLOG_DAILY_MAX_FILES=7
InstallCommand.php
- TrustProxies Configuration - During
coolify:install, modifiesbootstrap/app.phpto add$middleware->trustProxies(at: '*')inside thewithMiddlewarecallback. This properly configures Laravel to trust Coolify's reverse proxy.
Test plan
- All existing tests pass
- Lint passes
- Manual test of
coolify:installcommand - Manual test of
coolify:provisioncommand
Closes #11, #12, #14, #15, #16
Stu Mason + AI [email protected]
+86
additions
-16
deletions
2
files changed