compose/pkg
Nicolas De Loof b5cf514b29 fix(provider): clean up stale relay and guard start/restart against it
A provider that stops publishing endpoints on a later `up` left its
previously created relay running: deployRelay was only evaluated when
endpoints were non-empty, so a zero-endpoint up fell through with no
cleanup. The generic reconciler is no help either — it returns early
for any service.Provider != nil, before the recreate logic that would
otherwise catch this. runPlugin now removes any existing relay when a
provider publishes no endpoint on an up, whether it never did or
stopped doing so since a previous run.

Separately, startServiceContainer and restartContainer had no
relay-awareness at all, unlike exec/cp which already refuse to target
one via checkRelayTarget. A relay is a shell-less, FROM-scratch binary
standing in for the service on the network: it has no filesystem or
process for secrets/configs injection or PreStart/PostStart/PreStop
hooks to act on. Nothing in the compose-spec schema forbids declaring
secrets, configs or hooks on a provider: service, so this was reachable
in practice, not just in theory. Both now skip those steps for a relay
container while still starting/restarting the container itself
normally.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2026-09-17 17:51:23 +02:00
..
api feat(provider): publish-endpoint deploys a network relay for provider services 2026-09-16 17:03:23 +02:00
bridge fix(bridge): confirm before wiping non-empty convert output dir 2026-09-03 14:38:41 +02:00
compose fix(provider): clean up stale relay and guard start/restart against it 2026-09-17 17:51:23 +02:00
dryrun fix(dry-run): commit no longer creates a real image; the interception set becomes declarative 2026-09-16 13:44:21 +02:00
e2e fix(provider): stop reaches the relay container like down already does 2026-09-16 17:03:23 +02:00
mocks PRIVATE_PORT optional for docker compose port 2026-09-11 11:35:18 +02:00
remote golangci-lint: enable perfsprint linter 2026-09-10 10:25:34 +02:00
utils fix: make e2e tests pass reliably locally with Docker Desktop 2026-05-18 10:55:41 +02:00
watch golangci-lint: enable perfsprint linter 2026-09-10 10:25:34 +02:00