forked from rekibnikufesin/nodejs-logging-elk
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
69 lines (64 loc) · 1.58 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
version: '3'
services:
# NodeJS/ExpressJS server
express_server:
container_name: expressjs
build:
context: ./
dockerfile: Dockerfile
volumes:
- './:/app'
- '/app/node_modules'
ports:
- 3000:3000
- 9229:9229
environment:
- NODE_ENV=dev
entrypoint: ["npm", "run", "dev"]
# Elasticsearch
eslogs:
image: elasticsearch:7.8.0
container_name: eslogs
volumes:
- elasticsearch_data:/usr/share/elasticsearch/data
- ./elastic/elasticsearch.yaml:/usr/share/elasticsearch/config/elasticsearch.yml
ports:
- 9200:9200
- 9300:9300
environment:
discovery.type: single-node
# Kibana. Gotta have a pretty UI, amiright?
kibana_demo:
image: docker.elastic.co/kibana/kibana:7.8.0
container_name: kibana_demo
volumes:
- ./elastic/kibana.yaml:/usr/share/kibana/config/kibana.yml
ports:
- 5601:5601
# All hail the mighty, mighty LOOOOOOOGSTAAAAAAAAASH:
logstash_demo:
image: logstash:7.8.1
container_name: logstash_demo
volumes:
- ./elastic/logging.conf:/usr/share/logstash/pipeline/logging.conf
- ./elastic/logstash.yaml:/usr/share/logstash/config/logstash.yml
ports:
- 1514:1514/udp
- 1515:1515
- 1515:1515/udp
# Postgres DB for saving stuff
db:
image: postgres:latest
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: password
POSTGRES_DB: users
volumes:
- api_db_data:/var/lib/postgresql/data
ports:
- 5432:5432
volumes:
elasticsearch_data:
driver: local
api_db_data:
driver: local