-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdocker-compose.dev.yml
52 lines (48 loc) · 1.33 KB
/
docker-compose.dev.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
version: '3.9'
networks:
# single network for all services, only for development
dev:
services:
nx-dev:
build:
context: .
dockerfile: Dockerfile.dev
env_file:
- ./services/mongo/.env.dev
- ./services/postgres/.env.dev
container_name: snip-man-nx-dev
restart: always
entrypoint: >
bash -c "npm install -g npm@latest &&
npm install &&
npm run generate:prisma &&
npm run migrate:prisma &&
bash"
# Mount the repository root into the container for live file changes
volumes:
- ./:/usr/snip-man-dev/
ports:
- '5555:5555' # prisma studio mongo
- '5556:5556' # prisma studio postgres
- '4200:4200' # web
- '3333:3333' # server
networks:
dev:
postgres:
build: ./services/postgres
env_file: ./services/postgres/.env.dev
container_name: snip-man-postgres-dev
restart: always
ports:
- '15432:5432' # only to inspect the DB from the host with a db-admin tool, such as DataGrip
networks:
dev:
mongo:
build: ./services/mongo
env_file: ./services/mongo/.env.dev
container_name: snip-man-mongo-dev
restart: always
ports:
- '37017:27017' # only to inspect the DB from the host with a db-admin tool, such as DataGrip
networks:
dev: