forked from ClarityNLP/ClarityNLP
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
176 lines (161 loc) · 4.79 KB
/
docker-compose.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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
version: '3'
volumes:
mapper-pgdata:
mapper-redisdata:
nlp-solrdata:
nlp-pgdata:
nlp-mongodata:
# ingest-pgdata:
services:
nlp-api:
container_name: 'NLP_API'
hostname: ${NLP_API_HOSTNAME}
build:
context: ./nlp
dockerfile: Dockerfile
ports:
- "${NLP_API_HOST_PORT}:${NLP_API_CONTAINER_PORT}"
volumes:
- ./nlp:/api
command: ["/api/scripts/wait-for-it.sh", "${NLP_SOLR_HOSTNAME}:${NLP_SOLR_CONTAINER_PORT}", "${NLP_MONGO_HOSTNAME}:${NLP_MONGO_CONTAINER_PORT}", "${SCHEDULER_HOSTNAME}:${SCHEDULER_CONTAINER_PORT}", "${NLP_PG_HOSTNAME}:${NLP_PG_CONTAINER_PORT}", "--timeout=1800", "--", "python3", "api.py"]
env_file:
- .env
scheduler:
container_name: 'LUIGI_SCHEDULER'
hostname: ${SCHEDULER_HOSTNAME}
image: 'axiom/docker-luigi:2.7.1'
ports:
- "${SCHEDULER_HOST_PORT}:${SCHEDULER_CONTAINER_PORT}"
env_file:
- .env
nlp-solr:
container_name: 'NLP_SOLR'
hostname: ${NLP_SOLR_HOSTNAME}
build:
context: ./utilities/nlp-solr
dockerfile: Dockerfile
ports:
- "${NLP_SOLR_HOST_PORT}:${NLP_SOLR_CONTAINER_PORT}"
volumes:
- 'nlp-solrdata:/opt/solr/server/solr/mycores'
environment:
- SOLR_HEAP=4096m
env_file:
- .env
nlp-mongo:
container_name: 'NLP_MONGO'
image: mongo
hostname: ${NLP_MONGO_HOSTNAME}
environment:
- MONGO_DATA_DIR=/data/db
- MONGO_LOG_DIR=/dev/null
- MONGO_INITDB_DATABASE=${NLP_MONGO_DATABASE}
ports:
- "${NLP_MONGO_HOST_PORT}:${NLP_MONGO_CONTAINER_PORT}"
volumes:
- './utilities/nlp-mongo/setup.js:/docker-entrypoint-initdb.d/setup.js'
- 'nlp-mongodata:/data/db'
env_file:
- .env
nlp-postgres:
container_name: 'NLP_POSTGRES'
hostname: ${NLP_PG_HOSTNAME}
build:
context: ./utilities/nlp-postgres
dockerfile: Dockerfile
environment:
POSTGRES_USER: ${NLP_PG_USER}
POSTGRES_PASSWORD: ${NLP_PG_PASSWORD}
POSTGRES_DB: ${NLP_PG_DATABASE}
ports:
- "${NLP_PG_HOST_PORT}:${NLP_PG_CONTAINER_PORT}"
volumes:
- 'nlp-pgdata:/var/lib/postgresql/data/'
env_file:
- .env
ingest-api:
container_name: INGEST_API
hostname: ${INGEST_API_HOSTNAME}
build: ./utilities/ingest-api
volumes:
- ./utilities/ingest-api:/app
- /app/node_modules/ #empties container node_modules, forces bcrypt to be built on container
ports:
- "${INGEST_API_HOST_PORT}:${INGEST_API_CONTAINER_PORT}"
depends_on:
# - ingest-pg
- redis
environment:
- NODE_ENV=development
env_file:
- .env
# ingest-client:
# container_name: INGEST_CLIENT
# hostname: ${INGEST_CLIENT_HOSTNAME}
# build:
# context: ./utilities/ingest-client
# dockerfile: Dockerfile.prod
# ports:
# - "${INGEST_CLIENT_HOST_PORT}:${INGEST_CLIENT_CONTAINER_PORT}"
# ingest-pg:
# container_name: 'INGEST_POSTGRES'
# hostname: ${INGEST_PG_HOSTNAME}
# image: postgres
# environment:
# POSTGRES_USER: ${INGEST_PG_USER}
# POSTGRES_PASSWORD: ${INGEST_PG_PASSWORD}
# POSTGRES_DB: ${INGEST_PG_DATABASE}
# ports:
# - "${INGEST_PG_HOST_PORT}:${INGEST_PG_CONTAINER_PORT}"
# volumes:
# - 'ingest-pgdata:/var/lib/postgresql/data/'
mapper-api:
container_name: MAPPER_API
hostname: ${MAPPER_API_HOSTNAME}
build: ./utilities/mapper-api
volumes:
- ./utilities/mapper-api:/app
- /app/node_modules/ #empties container node_modules, forces bcrypt to be built on container
ports:
- "${MAPPER_API_HOST_PORT}:${MAPPER_API_CONTAINER_PORT}"
depends_on:
- mapper-pg
- redis
environment:
- NODE_ENV=development
mapper-client:
container_name: MAPPER_CLIENT
hostname: ${MAPPER_CLIENT_HOSTNAME}
build:
context: ./utilities/mapper-client
dockerfile: Dockerfile.prod
ports:
- "${MAPPER_CLIENT_HOST_PORT}:${MAPPER_CLIENT_CONTAINER_PORT}"
mapper-pg:
container_name: 'MAPPER_POSTGRES'
hostname: ${MAPPER_PG_HOSTNAME}
image: postgres
environment:
POSTGRES_USER: ${MAPPER_PG_USER}
POSTGRES_PASSWORD: ${MAPPER_PG_PASSWORD}
POSTGRES_DB: ${MAPPER_PG_DATABASE}
ports:
- "${MAPPER_PG_HOST_PORT}:${MAPPER_PG_CONTAINER_PORT}"
volumes:
- 'mapper-pgdata:/var/lib/postgresql/data/'
redis:
container_name: MAPPER_Redis
hostname: ${MAPPER_REDIS_HOSTNAME}
image: redis:3.2.0
ports:
- "${MAPPER_REDIS_HOST_PORT}:${MAPPER_REDIS_CONTAINER_PORT}"
volumes:
- 'mapper-redisdata:/data'
swagger:
container_name: MAPPER_Swagger_Docs
hostname: ${MAPPER_SWAGGER_HOSTNAME}
image: swaggerapi/swagger-ui
environment:
- "API_URL=${MAPPER_SWAGGER_API_URL}"
ports:
- "${MAPPER_SWAGGER_HOST_PORT}:${MAPPER_SWAGGER_CONTAINER_PORT}"