Fixes #7528
/claim #7528
When deploying Docker Compose files via GitHub App (using the dockercompose buildpack), database services are not detected and ServiceDatabase records are not created. This means automated backups are unavailable for databases in these deployments.
In bootstrap/helpers/shared.php, the parseDockerComposeFile() function has two paths:
isDatabaseImage() and creates ServiceDatabase records → backups workisDatabaseImage() but only sets a flag → no ServiceDatabase records → no backupsapplication_id column to service_databases table (alongside existing service_id)bootstrap/helpers/shared.php: Create ServiceDatabase records in the Application model path when isDatabaseImage() detects a database serviceServiceDatabase model: Add application() relationship and helper methods (getParentResource(), getServer(), getDestinationNetwork()) to support both Service and Application parent typesDatabaseBackupJob: Use getServer() helper for compatibility with both parent types| Deployment Method | Before | After |
|---|---|---|
| Empty Docker Compose (Service) | ✅ Backups work | ✅ Backups work (unchanged) |
| GitHub App dockercompose (Application) | ❌ No backups | ✅ Backups work |
| One-click Services | ✅ Backups work | ✅ Backups work (unchanged) |
LOLO
@artylobos
Ilias Ism
@me