Skip to content

dev-stack.sh down leaves the dApp dev server holding port 3012 #188

Description

@lmcorbalan

Description

down stops the containers and the pidfile-tracked processes, but the Vite dev server survives
and keeps listening on 3012. Its fallback pkill -f "vite --host localhost --port 3012" never
matches: app:dev passes its flags after --, so the real argv is
vite -- --host localhost --port 3012 --strictPort. stop_pidfile misses it too, because
pkill -P kills only direct children and vite is a grandchild of the recorded pid.

Steps to reproduce

  1. Start Docker, then run ./scripts/dev-stack.sh up
  2. Wait for "Stack is up" and confirm http://localhost:3012 answers
  3. Run ./scripts/dev-stack.sh down
  4. Run lsof -nP -iTCP:3012 -sTCP:LISTEN and see a node process still listening

Expected vs actual behavior

Expected: down frees 3010-3013 and its own port report prints (all free).
Actual: a node process still holds 3012, down's own report lists it, and the next up
warns "Port 3012 already in use" and skips the dApp.

Environment

Observed 2026-09-08 while running the stack on feat/185-dev-stack-no-dpm
The pkill pattern dates from 1dfa3ce (2026-06-11), unrelated to the token-forge migration

Additional context

Killing the recorded pid's whole process group would reach the grandchild; matching the real
argv would fix the fallback.

Activity

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

Metadata

Metadata

Labels

bugSomething isn't workingpriority: mediumShould be addressed soon

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions