Fix dev compose: npm install on container startup

The ./server bind mount overwrites /app/server including node_modules
installed during the Docker build. Running npm install on startup
ensures deps are present after the volume mount.

Also reverts the node_modules named-volume workaround in favor of
this cleaner approach (requires node installed locally for non-Docker dev).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-19 19:27:52 -04:00
parent e98abe632a
commit 3d41c623bc
4 changed files with 3118 additions and 7 deletions

View File

@@ -18,7 +18,13 @@
"Bash(docker --version)",
"Bash(docker compose:*)",
"Bash(docker build:*)",
"Bash(docker run:*)"
"Bash(docker run:*)",
"Bash(export PATH=\"/home/christian/.nvm/versions/node/v24.14.0/bin:$PATH\")",
"Bash(npm install:*)",
"Bash(npm run:*)",
"Bash(/home/christian/.nvm/versions/node/v24.14.0/bin/npm run:*)",
"Bash(PATH=\"/home/christian/.nvm/versions/node/v24.14.0/bin:$PATH\" npm run build 2>&1)",
"Bash(PATH=\"/home/christian/.nvm/versions/node/v24.14.0/bin:$PATH\" npx vite build 2>&1)"
]
}
}