Skip to content

[Bug]: PR previews don't take into account changes in the docker compose #7552

@Arnaud-IFEA

Description

@Arnaud-IFEA

Error Message and Logs

I made a change to my docker compose:
from:

environment:
      - 'DATABASE_URL=postgresql://devu:devp@postgresapp:23432/devdb'

to

environment:
      - 'DATABASE_URL=postgresql://devu:devp@${SERVICE_NAME_POSTGRESAPP}:23432/devdb'

i push the PR, and the PR fails with : DATABASE_URL=postgresql://devu:devp@postgresapp:23432/devdb
event though SERVICE_NAME_POSTGRESAPP=postgresapp-pr-241 in the container.

Steps to Reproduce

  1. in your docker compose, replace a hardcoded service name with a SERVICE_NAME_* variable
  2. create a PR and push the PR

Example Repository URL

No response

Coolify Version

v4.0.0-beta.452

Are you using Coolify Cloud?

No (self-hosted)

Operating System and Version (self-hosted)

Debian 12

Additional Information

In the environment variables section i have :
SERVICE_NAME_POSTGRESAPP=
that's the case for all SERVICE_NAME_* that appear in the Docker compose, i suppose this is normal, but confusing (maybe SERVICE_NAME_* should not appear in the the env section event if present in the docker compose).

Deployment log:

[CMD]: sudo docker exec zswww4gw8sk4cwc48owkk4o8 bash -c 'cat /artifacts/build-time.env'
COOLIFY_URL=''
COOLIFY_FQDN=''
SERVICE_NAME_POSTGRESAPP=""
SERVICE_NAME_POSTGRESPAYLOAD=""
SERVICE_NAME_MATOMO=""
SERVICE_NAME_MATOMODB='matomodb-pr-241'
SERVICE_NAME_OTELCOLLECTOR=""
SERVICE_NAME_GRAFANA='grafana-pr-241'
SERVICE_NAME_GRAFANALOKI='grafanaloki-pr-241'
SERVICE_NAME_GRAFANATEMPO='grafanatempo-pr-241'
SERVICE_NAME_PROMETHEUS='prometheus-pr-241' 
[CMD]: sudo docker exec zswww4gw8sk4cwc48owkk4o8 bash -c 'cat /artifacts/zswww4gw8sk4cwc48owkk4o8/.env'
SOURCE_COMMIT=10c3ef4aad35edf779e6eb39c4797112fb75dfe3
COOLIFY_URL=
COOLIFY_FQDN=
SERVICE_URL_APP=https://241.<url>
SERVICE_FQDN_APP=241.<url>
SERVICE_URL_MATOMO=https://241.matomo.<url>
SERVICE_FQDN_MATOMO=241.matomo.<url>
SERVICE_NAME_POSTGRESAPP=postgresapp-pr-241

Metadata

Metadata

Assignees

No one assigned

    Labels

    🐛 Possible BugReported issues that need to be reproduced by the team.🔍 TriageIssues that need assessment and prioritization.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions