From 9f64d3a18eb92c4845dac38265acecef2931490b Mon Sep 17 00:00:00 2001 From: Adam Mathes Date: Sun, 15 Feb 2026 14:11:19 -0800 Subject: Add devcontainer configuration and update documentation for containerized development --- .devcontainer/devcontainer.json | 8 ++------ README.md | 22 ++++++++++++++++++++++ 2 files changed, 24 insertions(+), 6 deletions(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index af4ea12..d7ada69 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -1,14 +1,10 @@ +// Note: This config is untested in Antigravity. Use vanilla Docker for reliability { - "name": "Neko (Podman)", + "name": "Neko (Dev)", "build": { "dockerfile": "Dockerfile", "context": ".." }, - "features": { - "ghcr.io/devcontainers/features/node:1": { - "node": "20" - } - }, "customizations": { "vscode": { "settings": { diff --git a/README.md b/README.md index 759a52e..ad0744b 100644 --- a/README.md +++ b/README.md @@ -131,6 +131,28 @@ Utility scripts and test wrappers are located in the `scripts/` directory: - `scripts/run_e2e_safe.sh`: A safe wrapper for running Playwright E2E tests. - `scripts/run_e2e.sh`: Standard E2E test runner. + +### Development with Containers + +If you don't have Go or Node installed locally, or prefer an isolated environment, you can use the provided Dockerfile. Note that the `.devcontainer` VS Code integration has encountered issues with some setups (e.g. Antigravity + Colima), so manual Docker commands are recommended as a fallback. + +1. **Build the development image**: + ```bash + docker build -t neko-dev -f .devcontainer/Dockerfile . + ``` + +2. **Run tests**: + ```bash + # Runs backend tests, installs frontend deps, and runs frontend tests + docker run --rm -v $(pwd):/workspace -w /workspace neko-dev \ + bash -c "go test ./... && cd frontend && npm install && npm test" + ``` + +3. **Interactive shell**: + ```bash + docker run -it --rm -v $(pwd):/workspace -w /workspace neko-dev bash + ``` + # Configuration Everything can handled with a few command line flags. You shouldn't need to change the defaults most of the time. -- cgit v1.2.3