Skip to content

Commit

Permalink
Pass --unsafe-perm flag to npm when running in Docker dev env.
Browse files Browse the repository at this point in the history
Works around #5.
  • Loading branch information
icedream committed Oct 6, 2017
1 parent e1cbaca commit 6241892
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
7 changes: 5 additions & 2 deletions docker-compose.dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,16 @@ services:
dockerfile: Dockerfile.dev

command: [sh, /app/install_and_run.sh]

tty: true

environment:
NPM_CONFIG_CACHE: /var/tmp/npm_cache
NODE_ENV: development

tmpfs:
- /tmp

volumes:
- .:/app
- npm_cache:/var/tmp/npm_cache
Expand Down
7 changes: 3 additions & 4 deletions install_and_run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

set -e

npm install --unsafe-perm
npm run build
exec npm run start:directly

npm --unsafe-perm install
npm --unsafe-perm run build
exec npm --unsafe-perm run start:directly

0 comments on commit 6241892

Please sign in to comment.