create alternate docker compose file for local dev

This commit is contained in:
Aadil Ayub 2024-01-24 16:50:39 +05:00
parent 5ac899e9d9
commit 7f5b8e7aa5

31
docker-compose-local.yml Normal file
View File

@ -0,0 +1,31 @@
version: '3'
services:
payload:
image: node:21-bookworm
ports:
- '3000:3000'
volumes:
- .:/home/node/app
- node_modules:/home/node/app/node_modules
working_dir: /home/node/app/
command: sh -c "yarn install && yarn dev"
depends_on:
- mongo
env_file:
- .env
mongo:
image: mongo:latest
ports:
- '27017:27017'
command:
- --storageEngine=wiredTiger
volumes:
- data:/data/db
logging:
driver: none
volumes:
data:
node_modules: