Add Docker and deployment config #6

Closed
opened 2026-08-02 14:42:34 +00:00 by Mark · 2 comments
Owner

Problem: The project only has a Vite dev server and production build. There is no Docker image, no static-file server configuration, and no deployment guidance for hosting the floorplan editor.

Files to add/modify:

  • Dockerfile using Node 20 and a static serving stage (nginx or distroless).
  • .dockerignore excluding node_modules and dist.
  • docker-compose.yml for local serving.
  • Update README.md with deployment instructions.

Acceptance criteria:

  • docker build -t kimi_agent_home_assistant . succeeds.
  • Container serves the built static files on a configurable port.
  • Image size is reasonable (< 100 MB final stage preferred).
**Problem:** The project only has a Vite dev server and production build. There is no Docker image, no static-file server configuration, and no deployment guidance for hosting the floorplan editor. **Files to add/modify:** - `Dockerfile` using Node 20 and a static serving stage (nginx or distroless). - `.dockerignore` excluding `node_modules` and `dist`. - `docker-compose.yml` for local serving. - Update `README.md` with deployment instructions. **Acceptance criteria:** - `docker build -t kimi_agent_home_assistant .` succeeds. - Container serves the built static files on a configurable port. - Image size is reasonable (< 100 MB final stage preferred).
Author
Owner

Closed by triage-runner.

Deliverable: commit f5ef457 (rebased onto origin/main from the original 45b6056) — fix(deploy): use prlimit with ulimit fallback so Docker build succeeds in restricted sandboxes.

Files added:

  • Dockerfile — multi-stage node:20-alpine build, prlimit/ulimit memory handling, serves built bundle via nginx
  • .dockerignore — excludes node_modules, .git, .worktrees, .venv, .gsd, tests
  • docker-compose.yml — single-service compose with port 8080:8080, healthcheck, restart policy
  • nginx.conf — SPA fallback to index.html, /healthz endpoint, gzip, security headers
  • README.md — Docker + docker compose quickstart sections

Verify gate (run on this host at 2026-09-18 09:16 PDT, all green):

  1. ls -la Dockerfile .dockerignore docker-compose.yml nginx.conf ✓
  2. docker build -t kimi_agent_home_assistant . ✓
  3. docker run --rm -d -p 8080:8080 --name kaha_test kimi_agent_home_assistant ✓
  4. sleep 2 && curl -fsS http://localhost:8080/healthz ✓
  5. curl -fsS http://localhost:8080/ | grep -q '<div id="root"></div>' ✓
  6. docker rm -f kaha_test ✓
  7. docker compose up -d --build ✓
  8. curl -fsS http://localhost:8080/healthz (compose) ✓
  9. docker compose down ✓

Push: 4 commits ahead (97de355..0ea4983) landed on origin/main at 2026-09-18T13:13Z via triage-runner recovery after tailnet substrate recovered.

Closes #6.

Closed by triage-runner. **Deliverable**: commit `f5ef457` (rebased onto origin/main from the original `45b6056`) — `fix(deploy): use prlimit with ulimit fallback so Docker build succeeds in restricted sandboxes`. **Files added**: - `Dockerfile` — multi-stage node:20-alpine build, prlimit/ulimit memory handling, serves built bundle via nginx - `.dockerignore` — excludes node_modules, .git, .worktrees, .venv, .gsd, tests - `docker-compose.yml` — single-service compose with port 8080:8080, healthcheck, restart policy - `nginx.conf` — SPA fallback to index.html, /healthz endpoint, gzip, security headers - `README.md` — Docker + docker compose quickstart sections **Verify gate** (run on this host at 2026-09-18 09:16 PDT, all green): 1. `ls -la Dockerfile .dockerignore docker-compose.yml nginx.conf` ✓ 2. `docker build -t kimi_agent_home_assistant .` ✓ 3. `docker run --rm -d -p 8080:8080 --name kaha_test kimi_agent_home_assistant` ✓ 4. `sleep 2 && curl -fsS http://localhost:8080/healthz` ✓ 5. `curl -fsS http://localhost:8080/ | grep -q '<div id="root"></div>'` ✓ 6. `docker rm -f kaha_test` ✓ 7. `docker compose up -d --build` ✓ 8. `curl -fsS http://localhost:8080/healthz` (compose) ✓ 9. `docker compose down` ✓ **Push**: 4 commits ahead (`97de355..0ea4983`) landed on origin/main at 2026-09-18T13:13Z via triage-runner recovery after tailnet substrate recovered. Closes #6.
Author
Owner

Closed by triage-runner.

Deliverable: commit f5ef457 (rebased onto origin/main from the original 45b6056) — fix(deploy): use prlimit with ulimit fallback so Docker build succeeds in restricted sandboxes.

Files added:

  • Dockerfile — multi-stage node:20-alpine build, prlimit/ulimit memory handling, serves built bundle via nginx
  • .dockerignore — excludes node_modules, .git, .worktrees, .venv, .gsd, tests
  • docker-compose.yml — single-service compose with port 8080:8080, healthcheck, restart policy
  • nginx.conf — SPA fallback to index.html, /healthz endpoint, gzip, security headers
  • README.md — Docker + docker compose quickstart sections

Verify gate (run on this host at 2026-09-18 09:16 PDT, all green):

  1. ls -la Dockerfile .dockerignore docker-compose.yml nginx.conf ✓
  2. docker build -t kimi_agent_home_assistant . ✓
  3. docker run --rm -d -p 8080:8080 --name kaha_test kimi_agent_home_assistant ✓
  4. sleep 2 && curl -fsS http://localhost:8080/healthz ✓
  5. curl -fsS http://localhost:8080/ | grep -q '<div id="root"></div>' ✓
  6. docker rm -f kaha_test ✓
  7. docker compose up -d --build ✓
  8. curl -fsS http://localhost:8080/healthz (compose) ✓
  9. docker compose down ✓

Push: 4 commits ahead (97de355..0ea4983) landed on origin/main at 2026-09-18T13:13Z via triage-runner recovery after tailnet substrate recovered.

Closes #6.

Closed by triage-runner. **Deliverable**: commit `f5ef457` (rebased onto origin/main from the original `45b6056`) — `fix(deploy): use prlimit with ulimit fallback so Docker build succeeds in restricted sandboxes`. **Files added**: - `Dockerfile` — multi-stage node:20-alpine build, prlimit/ulimit memory handling, serves built bundle via nginx - `.dockerignore` — excludes node_modules, .git, .worktrees, .venv, .gsd, tests - `docker-compose.yml` — single-service compose with port 8080:8080, healthcheck, restart policy - `nginx.conf` — SPA fallback to index.html, /healthz endpoint, gzip, security headers - `README.md` — Docker + docker compose quickstart sections **Verify gate** (run on this host at 2026-09-18 09:16 PDT, all green): 1. `ls -la Dockerfile .dockerignore docker-compose.yml nginx.conf` ✓ 2. `docker build -t kimi_agent_home_assistant .` ✓ 3. `docker run --rm -d -p 8080:8080 --name kaha_test kimi_agent_home_assistant` ✓ 4. `sleep 2 && curl -fsS http://localhost:8080/healthz` ✓ 5. `curl -fsS http://localhost:8080/ | grep -q '<div id="root"></div>'` ✓ 6. `docker rm -f kaha_test` ✓ 7. `docker compose up -d --build` ✓ 8. `curl -fsS http://localhost:8080/healthz` (compose) ✓ 9. `docker compose down` ✓ **Push**: 4 commits ahead (`97de355..0ea4983`) landed on origin/main at 2026-09-18T13:13Z via triage-runner recovery after tailnet substrate recovered. Closes #6.
Mark closed this issue 2026-09-18 20:14:18 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Mark/kimi_agent_home_assistant#6
No description provided.