Skip to content

Conversation

@OZCAP
Copy link

@OZCAP OZCAP commented Dec 13, 2025

Summary

When build server is enabled, $this->server is switched to point to $this->build_server before calling generate_compose_file(). Inside generate_compose_file(), the log drain configuration check was using $this->server which would incorrectly check the build server's settings instead of the deployment server where the container actually runs.

Changes

  • Changed $this->server->isLogDrainEnabled() to $this->original_server->isLogDrainEnabled() on line 2616

Root Cause

The $this->original_server variable is explicitly initialized to preserve the deployment server reference before any build server switching occurs. Log draining is a runtime concern for the deployment server, not a build-time concern for the build server.

User Impact

Users with build server enabled who have different configurations between their build and deployment servers will experience incorrect behavior. For example, enabling log draining on the deployment server has no effect because Coolify checks the build server's log drain settings instead.

Testing

  • Verified the change only affects the log drain configuration check
  • The fix ensures log drain configuration correctly references the deployment server

When build server is enabled, $this->server points to the build server.
The log drain configuration check was using $this->server which would
incorrectly check the build server's settings instead of the deployment
server where the container actually runs.

This fix ensures log drain configuration is correctly applied based on
the deployment server's settings by using $this->original_server.
@OZCAP
Copy link
Author

OZCAP commented Dec 14, 2025

In short, we discovered a bug in our production environment which prevents log drains from working on an application if a build server is connected. Really keen to have this resolved on the main release!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant