-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathdocker-compose.dev.yml
47 lines (45 loc) · 1.04 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
version: "3.1"
services:
mongo:
image: "mongo"
restart: always
ports:
- 27017:27017
environment:
MONGO_INITDB_ROOT_USERNAME: root
MONGO_INITDB_ROOT_PASSWORD: password
volumes:
- mongo:/data/db
- mongo_config:/data/configdb
api:
build:
dockerfile: Dockerfile.dev
context: ./server
ports:
- 3050:3050
volumes:
- /app/node_modules
- ./server:/app
environment:
# Use this to connect to the Docker MongoDB container
- DB_USER=root
- DB_USER_PWD=password
- DB_HOST=mongo:27017
# use this variable to connect to something like MongoDB Atlas
#- DB_URL="mongodb+srv://<username>:<password>@<host>/<database>?retryWrites=true&w=majority"
- PORT=3050
- TOKEN_KEY=secret
client:
build:
dockerfile: Dockerfile.dev
context: .
stdin_open: true
ports:
- 3000:3000
volumes:
- .:/app
environment:
- REACT_APP_MAHABHARATH_API="http://localhost:3050"
volumes:
mongo:
mongo_config: