forked from kernoio/devx-challenge
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
48 lines (43 loc) · 1.09 KB
/
docker-compose.yaml
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'
x-mongo-config:
&env_mongo
MONGODB_URI: mongodb://mongodb:27017/local-db?authSource=admin
MONGODB_USERNAME: root
MONGODB_PASSWORD: 8Jqi1hk4TRMltV4UGl5twmNvN
MONGODB_REPLICASET: rs0
MONGODB_REPLICA_SET_NAME: rs0
MONGODB_REPLICA_SET_MODE: primary
MONGODB_REPLICA_SET_KEY: replsetkey
MONGODB_ROOT_PASSWORD: 8Jqi1hk4TRMltV4UGl5twmNvN
MONGODB_ADVERTISED_HOSTNAME: mongodb
MONGODB_MIN_POOL_SIZE: 1
MONGODB_MAX_POOL_SIZE: 5
services:
ui:
image: node:18
hostname: ui
mem_limit: 4096MB
command: yarn start ui --host=0.0.0.0
working_dir: /usr/src/app
volumes: [ .:/usr/src/app ]
ports: [ '4200:4200' ]
environment:
PORT: 4200
<<: [ *env_mongo ]
api:
image: node:18
hostname: api
mem_limit: 4096MB
command: yarn start api
working_dir: /usr/src/app
volumes: [ .:/usr/src/app ]
ports: [ '3000:3000' ]
environment:
PORT: 4200
<<: [ *env_mongo ]
mongodb:
image: bitnami/mongodb:4.2 # mongo:4.2.3-bionic
hostname: mongodb
ports: [ '27018:27017' ]
environment:
<<: *env_mongo