You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: t3 start refuses to start after a container redeploy when the stale server record's PID belongs to another process #28229
I searched existing issues and did not find a duplicate.
I included enough detail to reproduce or investigate the problem.
Area
apps/server
Steps to reproduce
Run t3 start --base-dir <dir> in a container whose <dir> is on a persistent volume.
Redeploy, so the old container is killed without removing userdata/server-runtime.json.
The new container runs the same t3 start.
Expected behavior
A record left by a server in a previous container is ignored and the server starts.
Actual behavior
A T3 Code server is already running for /var/lib/tailscale/t3 (pid 1044, http://127.0.0.1:3773). Connect to that server, stop it before starting another, or use a different --base-dir.
PID 1044 belongs to an unrelated process in the new container's PID namespace, so isProcessAlive returns true and the server exits. The check in apps/server/src/cli/config.ts already skips a record carrying the new server's own PID ("A killed container can leave a record with the new server's own PID"), but not one whose PID another process has reused. Container PIDs are small and assigned in the same order on every boot, so this recurs.
Activity
Clear stale T3 runtime record before dcup starts the server (#276)
Clear stale T3 runtime record before dcup starts the server (#276)