Skip to content
Snippets Groups Projects
Commit 5c1e008c authored by Lukáš Kratochvíl's avatar Lukáš Kratochvíl
Browse files

feat: docker-compose - added mapping of package*.json files from the host to...

feat: docker-compose - added mapping of package*.json files from the host to the container, added comments describing what is happening and why
parent 932bc499
No related branches found
No related tags found
No related merge requests found
......@@ -15,7 +15,12 @@ services:
volumes:
# changes in host's ./backend directory will be propagated to the container
- ./backend:/usr/src/app
# this will let us add packages during development without rebuilding the image
# - we then need to install added packages (run 'npm i') inside the container in the folder '/usr/src'
- ./backend/package.json:/usr/src/package.json
- ./backend/package-lock.json:/usr/src/package-lock.json
# this prevents our host files from overriding container's node_modules
# – some packages may be platform specific so we always want to run 'npm i' in the container when new package is added
- exclude-server:/usr/src/app/node_modules/
environment:
- PORT=${SERVER_PORT}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment