-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.elk-full.yml
310 lines (295 loc) · 10.8 KB
/
docker-compose.elk-full.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
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
version: "3.7"
services:
# Database
postgres:
container_name: postgres
image: postgres:12.2-alpine # use official postgres version 12.2
restart: unless-stopped
volumes:
- database-data:/var/lib/postgresql/data/ # persist data even if container shuts down
environment:
POSTGRES_USER: docker
POSTGRES_PASSWORD: docker
POSTGRES_DB: acm
POSTGRES_HOST: localhost
POSTGRES_PORT: 5432
PGDATA: /var/lib/postgresql/data/
ports:
- target: 5432 # the port inside the container
published: 35432 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
# Database Administration Tool
pgadmin:
container_name: pgadmin
image: dpage/pgadmin4
depends_on:
- postgres
environment:
PGADMIN_DEFAULT_EMAIL: "[email protected]"
PGADMIN_DEFAULT_PASSWORD: "PgAdmin2020!"
volumes:
- ./mocks:/pgadmin4/mocks
- ./database.json:/pgadmin4/servers.json
ports:
- target: 80 # the port inside the container
published: 8080 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
# Website written in Angular
chapter-website:
container_name: Chapter-Website
image: chapter-website:v0.3.0
restart: unless-stopped
build:
context: ./Chapter-Website
dockerfile: Dockerfile
depends_on:
- half-dome
- tuolumne
- tenaya
ports:
- target: 4200 # the port inside the container
published: 4200 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
# Member Management API written in Nodejs
half-dome:
container_name: Half-Dome
image: half-dome:v0.2.7
restart: unless-stopped
build:
context: ./Half-Dome
dockerfile: Dockerfile
env_file:
- ./Half-Dome/.env
depends_on:
- postgres
- pgadmin
environment:
POSTGRES_HOST: host.docker.internal
POSTGRES_PORT: 35432
POSTGRES_DB: acm
POSTGRES_USER: docker
POSTGRES_PASSWORD: docker
ports:
- target: 4201 # the port inside the container
published: 4201 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
# Workshop Management API written in PHP
tuolumne:
container_name: Tuolumne
image: tuolumne:v1.0
restart: unless-stopped
build:
context: ./Tuolumne
dockerfile: Dockerfile
env_file:
- ./Tuolumne/.env
depends_on:
- postgres
- pgadmin
environment:
DB_HOST: host.docker.internal
DB_PORT: 35432
DB_DATABASE: acm
DB_USERNAME: docker
DB_PASSWORD: docker
ports:
- target: 4202 # the port inside the container
published: 4202 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
# Events Management API written in Golang
tenaya:
container_name: Tenaya
image: tenaya:v1.0
restart: unless-stopped
build:
context: ./Tenaya
dockerfile: Dockerfile
env_file:
- ./Tenaya/.env
depends_on:
- postgres
- pgadmin
environment:
DB_HOST: host.docker.internal
DB_PORT: 35432
DB_DATABASE: acm
DB_USER: docker
DB_PASSWORD: docker
PORT: 4203
ports:
- target: 4203 # the port inside the container
published: 4203 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
elasticsearch:
container_name: Elasticsearch
build:
context: ./elasticsearch/
args:
ELK_VERSION: $ELK_VERSION
volumes:
- type: bind
source: ./elasticsearch/config/elasticsearch.yml
target: /usr/share/elasticsearch/config/elasticsearch.yml
read_only: true
- type: volume
source: elasticsearch
target: /usr/share/elasticsearch/data
ports:
- target: 9200 # the port inside the container
published: 9200 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
- target: 9300 # the port inside the container
published: 9300 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
environment:
ES_JAVA_OPTS: "-Xmx256m -Xms256m"
ELASTIC_USERNAME: root
ELASTIC_PASSWORD: changeme
# Use single node discovery in order to disable production mode and avoid bootstrap checks
# see https://www.elastic.co/guide/en/elasticsearch/reference/current/bootstrap-checks.html
discovery.type: single-node
networks:
- elk
logstash:
container_name: Logstash
build:
context: ./logstash/
args:
ELK_VERSION: $ELK_VERSION
volumes:
- type: bind
source: ./logstash/config/logstash.yml
target: /usr/share/logstash/config/logstash.yml
read_only: true
- type: bind
source: ./logstash/pipeline
target: /usr/share/logstash/pipeline
read_only: true
ports:
- target: 5000 # the port inside the container
published: 5000 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
- target: 5000 # the port inside the container
published: 5000 # the publicly exposed port
protocol: udp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
- target: 9600 # the port inside the container
published: 9600 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
environment:
LS_JAVA_OPTS: "-Xmx256m -Xms256m"
networks:
- elk
depends_on:
- elasticsearch
kibana:
container_name: Kibana
build:
context: ./kibana/
args:
ELK_VERSION: $ELK_VERSION
volumes:
- type: bind
source: ./kibana/config/kibana.yml
target: /usr/share/kibana/config/kibana.yml
read_only: true
ports:
- target: 5601 # the port inside the container
published: 5601 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
networks:
- elk
depends_on:
- elasticsearch
apm-server:
container_name: APM_Server
build:
context: ./apm-server/
args:
ELK_VERSION: $ELK_VERSION
command:
# Disable strict permission checking on 'apm-server.yml' configuration file
# https://www.elastic.co/guide/en/beats/libbeat/current/config-file-permissions.html
- --strict.perms=false
volumes:
- type: bind
source: ./apm-server/config/apm-server.yml
target: /usr/share/apm-server/apm-server.yml
read_only: true
ports:
- target: 8200 # the port inside the container
published: 8200 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
networks:
- elk
depends_on:
- elasticsearch
enterprise-search:
container_name: Enterprise_Search
build:
context: ./enterprise-search/
args:
ELK_VERSION: $ELK_VERSION
volumes:
- type: bind
source: ./enterprise-search/config/enterprise-search.yml
target: /usr/share/enterprise-search/config/enterprise-search.yml
read_only: true
environment:
JAVA_OPTS: -Xmx2g -Xms2g
ENT_SEARCH_DEFAULT_PASSWORD: changeme
ports:
- target: 3002 # the port inside the container
published: 3002 # the publicly exposed port
protocol: tcp # the port protocol (tcp or udp)
mode: bridge # bridge networks are used to connect multiple containers together
networks:
- elk
depends_on:
- elasticsearch
logspout:
container_name: Logspout
build:
context: ./logspout
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
environment:
ROUTE_URIS: logstash://logstash:5000
LOGSTASH_TAGS: docker-elk
networks:
- elk
depends_on:
- logstash
restart: on-failure
curator:
container_name: Curator
build:
context: ./curator/
environment:
ELASTICSEARCH_HOST: elasticsearch
CRON: 0 0 * * *
CONFIG_FILE: /usr/share/curator/config/curator.yml
COMMAND: /usr/share/curator/config/delete_log_files_curator.yml
UNIT_COUNT: 2
networks:
- elk
depends_on:
- elasticsearch
networks:
elk:
driver: bridge
volumes:
elasticsearch:
database-data: # named volumes can be managed easier using docker-compose