feat(devenv): MCP dev hot-reload with image-based approach (#145)

Add mcp-build.sh that compiles the MCP binary and packages it as an
OCI image layer on top of the base rootfs, imported directly into
containerd. Air triggers rebuild on code changes, cleaning stale
containers automatically.

Consolidate dev-only files (Dockerfiles, entrypoint, config, build
script) into devenv/ to separate dev tooling from production artifacts.
Skip image pull when already imported to speed up dev startup.
This commit is contained in:
BBQ
2026-03-02 14:59:48 +08:00
committed by GitHub
parent f9f968f13f
commit 04bce702b7
12 changed files with 131 additions and 26 deletions
+1 -1
View File
@@ -2,7 +2,7 @@ root = "."
tmp_dir = "tmp"
[build]
cmd = "go build -o ./tmp/memoh-server ./cmd/agent/main.go"
cmd = "go build -o ./tmp/memoh-server ./cmd/agent/main.go && sh devenv/mcp-build.sh"
bin = "./tmp/memoh-server"
args_bin = ["serve"]
include_ext = ["go", "toml"]