Skip to content

fix: detach stdin from the migrate run — it swallowed the deploy script - #2

Open
MauriceDellin wants to merge 1 commit into
plexus-ms:mainfrom
MauriceDellin:fix/migrate-stdin-heredoc
Open

fix: detach stdin from the migrate run — it swallowed the deploy script#2
MauriceDellin wants to merge 1 commit into
plexus-ms:mainfrom
MauriceDellin:fix/migrate-stdin-heredoc

Conversation

@MauriceDellin

Copy link
Copy Markdown
Contributor

Fixes #1.

The remote half of scripts/deploy.sh arrives on stdin (ssh heredoc). docker compose run without -T attaches the one-shot migrate container to that stdin, so it consumes the remainder of the script — bash reads EOF right after the migration, dc up -d web and the health poll never execute, and the job exits 0: a silent no-op deploy that reports success.

Only stateful apps (§ 6.2 PLX) declare a migrate service, which is why the stateless plexus-ms.org deploys never surfaced this. Verified on tenant medocs (first stateful-app deploy): with -T the full pull → migrate → up → healthcheck chain runs; without it the log stops dead after the migration output.

One-character fix plus a comment explaining why the flag is load-bearing.

🤖 Generated with Claude Code

The remote half of deploy.sh arrives on stdin via the ssh heredoc.
`docker compose run` without -T attaches the migrate container to that
stdin, so it consumes the rest of the script: bash hits EOF right after
the migration, `up -d web` and the health poll never run, and the job
exits 0 — a silent no-op deploy that reports success.

Only stateful apps (§ 6.2 PLX) declare a migrate service, which is why
the stateless plexus-ms.org deploys never surfaced this.

Fixes plexus-ms#1

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.

deploy.sh: compose run migrate swallows the rest of the remote script via stdin

1 participant