-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
49 lines (48 loc) · 1.37 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
version: '2'
services:
server:
# build will build the image from the dockerfile
# found at the specified path. Which will be in
# the same directory.
build: ./
# tags our built image
image: server:logging
# the command executes main binary on container start up
# this starts our go server.
command: sh -c '/main'
ports:
- 8080:8080
environment:
- 'LOGSTASH=logstash:5000'
links:
- logstash
elasticsearch:
# pull image from docker hub
image: elasticsearch:2.4.2
ports:
- 9200:9200
- 9300:9300
environment:
# set heap memory
ES_JAVA_OPTS: '-Xms1g -Xmx1g'
kibana:
# pull image from docker hub
image: kibana:4.6.3
ports:
- 5601:5601
environment:
- ELASTICSEARCH_URL=http://elasticsearch:9200
links:
- elasticsearch
logstash:
# pull image from docker hub
image: logstash:5.5.2
# specify the configuration file
command: -f /etc/logstash/conf.d/logstash.conf
ports:
- 5000:5000
volumes:
# mount local conf file onto container
- ./logstash.conf:/etc/logstash/conf.d/logstash.conf
links:
- elasticsearch