wasmrun stop
Stop any running wasmrun server instance.
Synopsisâ
wasmrun stop
Aliases: kill
Descriptionâ
Gracefully terminates a running wasmrun development server. Sends SIGTERM to allow cleanup, connection closing, and temp file removal.
Usageâ
# Stop the running server
wasmrun stop
Output when a server is running:
đ Stopping Wasmrun server...
â Server stopped (PID: 12345)
Output when no server is running:
âšī¸ No Wasmrun server is currently running
How It Worksâ
- Reads the PID from
.wasmrun-server/pid - Sends SIGTERM to the process
- Waits for graceful shutdown
- Removes the PID and port tracking files
Examplesâ
Stop and Restartâ
wasmrun stop
wasmrun run ./my-project --port 3000
Stop Before Switching Projectsâ
wasmrun stop
cd ../other-project
wasmrun run
Port Conflict Resolutionâ
# "Port 8420 already in use"
wasmrun stop
wasmrun run --port 8420
Force Stopâ
If wasmrun stop doesn't respond:
# Find the process
ps aux | grep wasmrun
# Force kill
pkill -9 wasmrun
Server State Filesâ
wasmrun tracks the server process in:
.wasmrun-server/
âââ pid # Process ID
âââ port # Port number
These are created on server start and cleaned up on stop.