Pull Request Merged
PR #25 merged: feat: store resource config in database instead of .env
Summary
- Store provisioned resource UUIDs in
coolify_resourcesdatabase table instead of.envfile - All commands now read from
CoolifyResource::getDefault()instead of config - ProvisionCommand saves to database after successful provisioning
- Dashboard reads from database for resource information
Changes
New files:
database/migrations/create_coolify_resources_table.php- Migration for resource storagesrc/Models/CoolifyResource.php- Eloquent model withgetDefault()helper
Updated:
- All console commands (Deploy, Status, Logs, Restart, Rollback)
- DashboardStatsController
- Coolify facade
- Config file (removed resource UUID settings)
- 10 documentation files
Database Schema
| Column | Description |
|---|---|
name | Application name (unique) |
server_uuid | Coolify server |
project_uuid | Coolify project |
environment | Environment name |
application_uuid | Application UUID |
database_uuid | PostgreSQL UUID |
redis_uuid | Dragonfly/Redis UUID |
deploy_key_uuid | SSH key UUID |
is_default | Default resource for commands |
Test plan
- All 184 tests pass
- PHPStan passes
- Tested with real Coolify instance - provision and status work correctly
- Documentation updated
Stu Mason + AI [email protected]
+525
additions
-467
deletions
31
files changed