Skip to content

fix: use compose file directory for compose builds#9815

Open
MestreY0d4-Uninter wants to merge 1 commit intocoollabsio:nextfrom
MestreY0d4-Uninter:fix/docker-compose-subdir-project-directory-v2
Open

fix: use compose file directory for compose builds#9815
MestreY0d4-Uninter wants to merge 1 commit intocoollabsio:nextfrom
MestreY0d4-Uninter:fix/docker-compose-subdir-project-directory-v2

Conversation

@MestreY0d4-Uninter
Copy link
Copy Markdown

@MestreY0d4-Uninter MestreY0d4-Uninter commented Apr 26, 2026

Changes

  • Use the compose file directory as the build-time project directory when a Docker Compose file lives in a subfolder.
  • Keep root-level compose files on the existing deployment workdir behavior.
  • Apply the same calculation to custom compose build commands unless the user already supplied a project directory.
  • Add regression coverage for nested and root compose file locations.

Issues

Category

  • Bug fix
  • Improvement
  • New feature
  • Adding new one click service
  • Fixing or updating existing one click service

Preview

N/A; backend deployment command fix.

AI Assistance

  • AI was NOT used to create this PR
  • AI was used (please describe below)

If AI was used:

  • Tools used: Hermes Agent/Codex for investigation, edit, and validation.
  • How extensively: AI-assisted implementation with human-directed scope and local verification.

Testing

  • Focused Pest regression for nested/root compose build commands passed.
  • Full custom compose build command unit test file passed.
  • Related compose start command unit test file passed.
  • Pint dirty format check passed.
  • PHP syntax checks passed for the changed PHP files.
  • Docker Compose smoke confirmed that a nested compose file resolves parent build context from the compose directory, not the deployment root.
  • Local Coolify dev stack was built and started successfully; health, login, dashboard, Horizon, and Mailpit responded.
  • The focused and related compose tests also passed inside the running local dev container.

Contributor Agreement

Important

  • I have read and understood the contributor guidelines. If I have failed to follow any guideline, I understand that this PR may be closed without review.
  • I have searched existing issues and pull requests (including closed ones) to ensure this isn't a duplicate.
  • I have tested all the changes thoroughly with a local development instance of Coolify and I am confident that they will work as expected when a maintainer tests them.

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