-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
163 lines (152 loc) · 4.92 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
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
services:
########################
# third-party backends #
########################
zookeeper:
image: confluentinc/cp-zookeeper:7.0.1
container_name: "zookeeper"
environment:
ZOOKEEPER_CLIENT_PORT: 2181
ZOOKEEPER_TICK_TIME: 2000
ports:
- 22181:2181
kafka:
# Kafka 3.0
image: confluentinc/cp-kafka:7.0.1
container_name: "kafka"
depends_on:
- zookeeper
ports:
- 29092:9092
environment:
KAFKA_BROKER_ID: 1
KAFKA_ZOOKEEPER_CONNECT: zookeeper:2181
KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://kafka:9092,PLAINTEXT_HOST://localhost:29092
KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: PLAINTEXT:PLAINTEXT,PLAINTEXT_HOST:PLAINTEXT
KAFKA_INTER_BROKER_LISTENER_NAME: PLAINTEXT
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1
KAFKA_ADVERTISED_HOST_NAME: kafka
LOG4J_LOGGER_KAFKA: INFO
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:${ELASTIC_VERSION:-8.13.3}
container_name: "elasticsearch"
environment:
- discovery.type=single-node
- cluster.name=elasticsearch
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
- node.name=docker-node
- xpack.security.enabled=false
- xpack.security.http.ssl.enabled=false
- xpack.security.transport.ssl.enabled=false
ports:
- 9200:9200
mongodb:
image: mongo:5.0
container_name: "mongodb"
ports:
- 27017:27017
volumes:
- ./scripts/file.key:/data/file.key
- ./scripts/rs-init.sh:/scripts/rs-init.sh
links:
- mongo2
- mongo3
command:
- /bin/sh
- -c
- |
chmod 400 /data/file.key
mongod --bind_ip_all --auth --keyFile /data/file.key --replSet dbrs --port 27017
mongo2:
image: mongo:5.0
container_name: mongo2
ports:
- 27019:27017
volumes:
- ./scripts/file.key:/data/file.key
command:
- /bin/sh
- -c
- |
chmod 400 /data/file.key
mongod --bind_ip_all --auth --keyFile /data/file.key --replSet dbrs --port 27017
mongo3:
image: mongo:5.0
container_name: mongo3
ports:
- 27022:27017
volumes:
- ./scripts/file.key:/data/file.key
command:
- /bin/sh
- -c
- |
chmod 400 /data/file.key
mongod --bind_ip_all --auth --keyFile /data/file.key --replSet dbrs --port 27017
#########
# ARLAS #
#########
arlas-server:
image: gisaia/arlas-server:${ARLAS_VERSION:-25.1.0}
container_name: "arlas-server"
ports:
- 9999:9999
depends_on:
- elasticsearch
environment:
- ARLAS_ELASTIC_NODES=${ARLAS_ELASTIC_NODES:-elasticsearch:9200}
- ARLAS_ELASTIC_ENABLE_SSL="${ARLAS_ELASTIC_ENABLE_SSL:-false}"
- ARLAS_ELASTIC_CREDENTIALS="${ARLAS_ELASTIC_CREDENTIALS}"
- ARLAS_ELASTIC_SKIP_MASTER="${ARLAS_ELASTIC_SKIP_MASTER:-true}"
arlas-subscriptions-matcher:
build:
context: .
dockerfile: Dockerfile-matcher
image: gisaia/arlas-subscriptions-matcher:${ARLAS_SUBSCRIPTIONS_VERSION:-latest}
container_name: "arlas-subscriptions-matcher"
depends_on:
- arlas-server
- kafka
environment:
- KAFKA_BROKERS=kafka:9092
- ARLAS_SUB_ELASTIC_NODES=elasticsearch:9200
- ARLAS_SERVER=arlas-server:9999
- ARLAS_SERVER_BASE_PATH=http://arlas-server:9999/arlas
- ARLAS_SUBSCRIPTIONS_BASE_PATH=http://arlas-server:9999/arlas
- ARLAS_SUB_IDENTITY_HEADER=${ARLAS_SUB_IDENTITY_HEADER:-}
- ARLAS_SUB_MATCHER_LOGGING_LEVEL=${ARLAS_SUB_MATCHER_LOGGING_LEVEL:-INFO}
- ARLAS_SUB_MATCHER_LOGGING_CONSOLE_LEVEL=${ARLAS_SUB_MATCHER_LOGGING_CONSOLE_LEVEL:-INFO}
ports:
- 9997:9998
healthcheck:
test: curl http://localhost:9998/admin/healthcheck | grep -v "\"healthy\":false" || exit 1
interval: 30s
timeout: 30s
retries: 3
arlas-subscriptions-manager:
build:
context: .
dockerfile: Dockerfile-manager
image: gisaia/arlas-subscriptions-manager:${ARLAS_SUBSCRIPTIONS_VERSION:-latest}
container_name: "arlas-subscriptions-manager"
depends_on:
- mongodb
- elasticsearch
environment:
- MONGO_HOST=mongodb:27017,mongo2:27017,mongo3:27017
- MONGO_USERNAME=${MONGO_USERNAME:-mongouser}
- MONGO_PASSWORD=${MONGO_PASSWORD:-secret}
- MONGO_AUTH_DATABASE=${MONGO_AUTH_DATABASE:-admin}
- ARLAS_SUB_ELASTIC_NODES=elasticsearch:9200
- ARLAS_SUB_ELASTIC_INDEX=subs
- ARLAS_SUB_TRIG_SCHEM_PATH=${ARLAS_SUB_TRIG_SCHEM_PATH:-/opt/app/trigger.schema.json}
- ARLAS_SUB_IDENTITY_HEADER=${ARLAS_SUB_IDENTITY_HEADER:-}
volumes:
- ${ARLAS_SUB_TRIG_SCHEM_PATH_LOCAL:-./subscriptions-tests/src/test/resources/trigger.schema.json}:${ARLAS_SUB_TRIG_SCHEM_PATH:-/opt/app/trigger.schema.json}
ports:
- 9998:9998
healthcheck:
test: curl http://localhost:9998/admin/healthcheck | grep -v "\"healthy\":false" || exit 1
interval: 30s
timeout: 30s
retries: 3