forked from inveniosoftware-contrib/citadel-search
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.test.yml
175 lines (164 loc) · 3.71 KB
/
docker-compose.test.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
version: "2.3"
services:
cern-search-api:
build:
context: .
args:
build_env: ${ENV}
image: cern-search-rest-api
container_name: ${CONTAINER_NAME}
volumes:
- ./:/opt/invenio/src:delegated
- cern_search_rest_api.egg-info:/opt/invenio/src/cern_search_rest_api.egg-info
- files:/usr/share/cern-search-api/files
ports:
- "5000:5000"
depends_on:
elasticsearch:
condition: service_healthy
redis:
condition: service_started
postgres:
condition: service_started
rabbitmq:
condition: service_healthy
networks:
- default
env_file:
- .env
user: root
worker:
image: cern-search-rest-api
volumes:
- ./:/opt/invenio/src:delegated
- cern_search_rest_api.egg-info:/opt/invenio/src/cern_search_rest_api.egg-info
- files:/usr/share/cern-search-api/files
depends_on:
cern-search-api:
condition: service_started
elasticsearch:
condition: service_healthy
redis:
condition: service_started
postgres:
condition: service_started
rabbitmq:
condition: service_healthy
networks:
- default
env_file:
- .env
user: root
command: [
"/bin/bash",
"-c",
"celery worker -A ${WORKER_APP} -l DEBUG --autoscale=10,1"
]
healthcheck:
test: ["CMD", "celery inspect ping -A ${WORKER_APP} -d celery@$$(hostname)"]
interval: 60s
timeout: 10s
retries: 5
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch-oss:7.1.1
ports:
- "9200:9200"
- "9300:9300"
environment:
discovery.type: single-node
networks:
- default
volumes:
- es-data:/usr/share/elasticsearch/data
healthcheck:
test: ["CMD", "curl", "-f", "localhost:9200/_cluster/health?wait_for_status=yellow"]
interval: 30s
timeout: 10s
retries: 5
kibana:
image: docker.elastic.co/kibana/kibana-oss:7.1.1
depends_on:
elasticsearch:
condition: service_healthy
ports:
- 5601:5601
networks:
- default
redis:
image: redis:5.0.6
ports:
- 6379:6379
networks:
- default
postgres:
image: centos/postgresql-95-centos7
environment:
- POSTGRESQL_USER
- POSTGRESQL_PASSWORD
- POSTGRESQL_DATABASE
volumes:
- pgsql-data:/var/lib/pgsql/data
networks:
- default
ports:
- 5432:5432
nginx:
image: nginx:1.17.4-alpine
ports:
- "8080:8080"
depends_on:
- cern-search-api
volumes:
- ./nginx/tls:/etc/nginx/tls
- nginx-cache:/var/cache/nginx
- nginx-run:/var/run
- ./nginx/nginx.conf:/etc/nginx/nginx.conf
rabbitmq:
image: rabbitmq:3.8.2-management
env_file:
- .env
restart: "always"
ports:
- "15672:15672"
- "5672:5672"
networks:
- default
healthcheck:
test: ["CMD", "rabbitmqctl", "node_health_check"]
interval: 60s
timeout: 10s
retries: 3
flower:
image: mher/flower
env_file:
- .env
command: [
"--broker=amqp://guest:${RABBITMQ_DEFAULT_PASS}@rabbitmq:5672",
"--broker_api=http://guest:${RABBITMQ_DEFAULT_PASS}@rabbitmq:15672/api",
"--basic_auth=admin:${FLOWER_PASS}"
]
ports:
- "5555:5555"
depends_on:
rabbitmq:
condition: service_healthy
redis:
condition: service_started
networks:
- default
tika:
image: apache/tika:1.24
ports:
- "9998:9998"
networks:
- default
networks:
default:
volumes:
es-data:
pgsql-data:
nginx-run:
nginx-cache:
nginx-tls:
cern_search_rest_api.egg-info:
files: