The deployment failed on the migrate service. Coolify rewrites a relative bind mount to a path under its own application directory, and when that resolves to an empty directory golang-migrate finds no migrations and exits 1 - with nothing useful in the deployment log to say why. A deployment that pulls its images has no business also depending on files being at a particular path on the host. Both mounts are now baked into images built from the repository root: migrations - the schema, so migrate always has it rspamd - actions.conf and ratelimit.conf The Rspamd one mattered for a quieter reason: Rspamd starts happily with an empty local.d, so a mount that resolved to nothing would have left the rate limits and score thresholds unapplied. The defence would have looked configured and done nothing. Both images join the CI and release matrices, building from the root context. Verified by building them, checking their contents, and bringing the whole stack up - Rspamd reports its nine rate directives loaded from the image. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
33 lines
908 B
YAML
33 lines
908 B
YAML
# Development overlay: builds the images from source instead of pulling them.
|
|
#
|
|
# Production deploys pull what CI already built and tested, so the compose file
|
|
# proper carries no build definitions - rebuilding four images on the target
|
|
# host is slow and, on a small server, the webmail build is enough to fail the
|
|
# deployment outright.
|
|
#
|
|
# Use it explicitly:
|
|
# docker compose -f docker-compose.yaml -f docker-compose.build.yaml up --build
|
|
services:
|
|
auth:
|
|
build: { context: ./services/auth }
|
|
|
|
storage:
|
|
build: { context: ./services/storage }
|
|
|
|
protocols:
|
|
build: { context: ./services/protocols }
|
|
|
|
web:
|
|
build: { context: ./services/webmail }
|
|
|
|
# These two carry repository files, so their context is the root.
|
|
migrate:
|
|
build:
|
|
context: .
|
|
dockerfile: services/migrations/Dockerfile
|
|
|
|
rspamd:
|
|
build:
|
|
context: .
|
|
dockerfile: services/rspamd/Dockerfile
|