Commit 8ef0e20
committed
fix(compose): preserve image node_modules from host bind mount
The webhook and dev composes mount ../:/app, which shadowed the
node_modules built by `RUN npm install` in Dockerfile.dev with whatever
(usually empty) node_modules sat in the host repo. The webhook
entrypoint then ran `rosemary webpack:compile`, npx webpack tried to
self-install webpack-cli and aborted, taking the container down.
Add an anonymous volume on /app/node_modules in every service that
bind-mounts the repo (web/worker on prod.webhook.yml; worker on dev.yml
— web on dev.yml already had it). The image's node_modules is now
authoritative, and the host no longer needs Node installed.1 parent b4eded8 commit 8ef0e20
2 files changed
Lines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
| 35 | + | |
35 | 36 | | |
36 | 37 | | |
37 | 38 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
16 | 17 | | |
17 | 18 | | |
18 | 19 | | |
| |||
31 | 32 | | |
32 | 33 | | |
33 | 34 | | |
| 35 | + | |
34 | 36 | | |
35 | 37 | | |
36 | 38 | | |
| |||
0 commit comments