Docker: five images ignore docker stop and are killed at the timeout
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 48/100
- Issue 类型
- 缺陷
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 技术栈
- docker, typescript
- 领域
- devops, infrastructure
调研方向
Read the five affected image definitions under src/filesystem, src/sequentialthinking, src/fetch, src/git, and src/time, then compare their stop behavior with everything and memory. Run the provided Docker reproduction and inspect scripts/image-smoke.mjs for the cleanStop checks. Done means all five containers stop promptly with their server's exit and the smoke entries assert clean stops; the signal handling approach still needs a decision.
由索引模型根据 Issue 内容生成。
描述
Problem
Five of the seven Docker images do not exit on docker stop: filesystem, sequentialthinking, fetch, git and time. Docker sends the stop signal, the server ignores it, and Docker kills the container when its timeout runs out (exit 137). everything and memory exit on their own (exit 0 and 130), because their images declare STOPSIGNAL SIGINT and their servers handle it (#5485 for memory).
The cause is the same in each: the server runs as PID 1, which gets no default signal disposition, so a SIGTERM it installed no handler for is dropped.
Found while building the image smoke for #5598, which asserts a clean stop only for the two images that have one today.
Reproduce
Built from v2/main at 7f383a8e, Docker 29.8.1:
docker build -f src/filesystem/Dockerfile -t mcp/filesystem .
id=$(docker run -d -i mcp/filesystem /tmp)
docker stop "$id" # waits out the timeout
docker inspect -f '{{.State.ExitCode}}' "$id" # 137
The same for sequentialthinking, and for fetch, git and time built from their own directories. All five exit 137; everything exits 0 and memory 130.
Expected
docker stop ends each container promptly and with the server's own exit, as it does for everything and memory. None of the five keeps state that a kill corrupts today, so what a user sees is the stop taking the full timeout (10 seconds by default), per container, on every docker stop, docker compose down or orchestrator restart, most visibly when the server runs over Streamable HTTP.
To decide
- Per image: a
STOPSIGNALthe server already handles, a signal handler in the server, or an init process (docker run --init,tini) in the image. - When an image gains a clean stop, set
cleanStop: trueon its entry inscripts/image-smoke.mjs, so the image smoke asserts it (a script test already requires it of any image that declares aSTOPSIGNAL).
- 主要语言
- TypeScript
- 星标
- 92k
- 派生
- 12k
- 平均合并
- 3 小时 46 分钟
- 30 天内合并 PR
- 206
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
modelcontextprotocol/servers 的其他 Issue
-
`interface-diff` discards the git error when resolving its default base and reports the wrong cause未关闭
难度 2/5 1-3 小时 新手友好度 82/100
modelcontextprotocol/servers#5636 ·
维护者通常 1 天内回复
-
chore server-memory v2
难度 2/5 1-3 小时 新手友好度 76/100
modelcontextprotocol/servers#5634 ·
维护者通常 1 天内回复
-
documentation server-memory v2
难度 1/5 1 小时以内 新手友好度 90/100
modelcontextprotocol/servers#5609 · 1 条评论 ·
维护者通常 1 天内回复
-
bug server-memory v2
难度 4/5 3-5 天 新手友好度 48/100
modelcontextprotocol/servers#5635 · 1 条评论 ·
维护者通常 1 天内回复
-
bug server-memory v2
难度 5/5 一周以上 新手友好度 42/100
modelcontextprotocol/servers#5624 ·
维护者通常 1 天内回复
查看 modelcontextprotocol/servers 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 79/100
hurttlocker/o8#6535 ·
-
难度 2/5 1-3 小时 新手友好度 77/100
维护者通常 1 天内回复
-
area: backend bug priority: low
难度 2/5 1-3 小时 新手友好度 92/100
snapotter-hq/SnapOtter#4856 ·
维护者通常 1 天内回复
-
bug follow-up
难度 1/5 1-3 小时 新手友好度 88/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
spellshift/realm#2509 ·
维护者通常 1 天内回复