-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.prod.yml
48 lines (48 loc) · 1.2 KB
/
docker-compose.prod.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
version: '3.9'
services:
frontend:
container_name: frontend
build:
context: ./frontend
dockerfile: Dockerfile.prod
ports:
- 3000:80
environment:
- REACT_APP_BACKEND_URI=${BACKEND_URI}
backend:
container_name: backend
build:
context: ./backend
dockerfile: Dockerfile.prod
restart: always
ports:
- 5000:8000
environment:
- MONGO_USERNAME=${MONGO_USERNAME}
- MONGO_PASSWORD=${MONGO_PASSWORD}
- FRONTEND_URI=${FRONTEND_URI}
database:
container_name: database
image: mongo
restart: always
ports:
- 27017:27017
volumes:
- './mongo/db:/data/db'
environment:
MONGO_INITDB_ROOT_USERNAME: ${MONGO_USERNAME}
MONGO_INITDB_ROOT_PASSWORD: ${MONGO_PASSWORD}
portal:
container_name: portal
image: mongo-express
restart: always
ports:
- 3300:8081
environment:
ME_CONFIG_BASICAUTH_USERNAME: ${MONGO_WEB_USERNAME}
ME_CONFIG_BASICAUTH_PASSWORD: ${MONGO_WEB_PASSWORD}
ME_CONFIG_MONGODB_ADMINUSERNAME: ${MONGO_USERNAME}
ME_CONFIG_MONGODB_ADMINPASSWORD: ${MONGO_PASSWORD}
ME_CONFIG_MONGODB_SERVER: 'database'
depends_on:
- database