feat(preview-env): add production variable fallback for docker-compose

When preview environment variables are configured, fall back to production
variables for keys not overridden by preview values. This ensures variables
like DB_PASSWORD that exist only in production are available in the preview
.env file, enabling proper ${VAR} interpolation in docker-compose YAML.

Fallback only applies when preview variables are configured, preventing
unintended leakage of production values when previews aren't in use.

Also improves UI by hiding the Domains section when only database services
are present, and simplifies the logs view by removing status checks.
This commit is contained in:
Andras Bacsai
2026-03-25 13:26:50 +01:00
parent c2c18a2f0f
commit 3034e89edb
6 changed files with 318 additions and 46 deletions
+5
View File
@@ -32,6 +32,11 @@ use OpenApi\Attributes as OA;
)]
class EnvironmentVariable extends BaseModel
{
protected $attributes = [
'is_runtime' => true,
'is_buildtime' => true,
];
protected $fillable = [
// Core identification
'key',