-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
132 lines (122 loc) · 3.58 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
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
version: '3'
networks:
frontend:
driver: ${NETWORKS_DRIVER}
backend:
driver: ${NETWORKS_DRIVER}
volumes:
elasticsearch-data:
driver: ${VOLUMES_DRIVER}
services:
elasticsearch:
restart: always
build:
context: elasticsearch/
args:
- ELK_VERSION=${ELK_VERSION}
volumes:
- elasticsearch-data:/usr/share/elasticsearch/data
- ./elasticsearch/config/elasticsearch.yml:/usr/share/elasticsearch/config/elasticsearch.yml
environment:
- xpack.monitoring.templates.enabled=true
- xpack.watcher.enabled=false
- "ES_JAVA_OPTS=-Xms1800m -Xmx1800m"
- discovery.type=single-node
- ELASTICSEARCH_USERNAME="elastic"
- ELASTIC_PASSWORD=${ELASTICSEARCH_PASSWORD}
ports:
- "9200:9200"
- "9300:9300"
networks:
- frontend
- backend
kibana:
restart: always
build:
context: kibana/
args:
ELK_VERSION: $ELK_VERSION
# volumes:
# - ./kibana/config/kibana.yml:/usr/share/kibana/config/kibana.yml
environment:
- ELASTICSEARCH_URL=http://elasticsearch:9200
- ELASTICSEARCH_HOSTS=["http://elasticsearch:9200"]
- ELASTICSEARCH_USERNAME="kibana_system"
- ELASTICSEARCH_PASSWORD=${KIBANA_PASSWORD}
ports:
- "5601:5601"
depends_on:
- elasticsearch
networks:
- frontend
- backend
# logstash:
# restart: always
# build:
# context: logstash/
# args:
# - ELK_VERSION=${ELK_VERSION}
# volumes:
# - ./logstash/config/logstash.yml:/usr/share/logstash/config/logstash.yml
# - ./logstash/pipeline/:/usr/share/logstash/pipeline/
# ports:
# - "5044:5044"
# - "5000:5000/tcp"
# - "5000:5000/udp"
# - "9600:9600"
# environment:
# LS_JAVA_OPTS: "-Xmx600m -Xms600m"
# ELASTIC_PASSWORD: ${ELASTICSEARCH_PASSWORD}
# networks:
# - frontend
# - backend
# depends_on:
# - elasticsearch
apm-server:
build:
context: apm/
args:
- ELK_VERSION=${ELK_VERSION}
environment:
ELASTIC_PASSWORD: ${ELASTICSEARCH_PASSWORD}
ports:
- 8200:8200
depends_on:
- elasticsearch
- kibana
networks:
- frontend
- backend
# nginx:
# container_name: nginx
# image: nginx:stable
# restart: always
# depends_on:
# - certbot
# volumes:
# - ./nginx/sites/:/etc/nginx/conf.d/:ro
# - ./nginx/nginx.conf:/etc/nginx/nginx.conf:ro
# - ./nginx/.htpasswd:/etc/nginx/.htpasswd:ro
# - ./nginx/conf/:/etc/nginx/conf
# - ${VOLUME_PATH}/nginx/logs/:/var/log/nginx
# - ${VOLUME_PATH}/certbot/www:/var/www/certbot/:ro
# - ${VOLUME_PATH}/certbot/conf/:/etc/nginx/ssl/:ro
# ports:
# - 80:80
# - 443:443
# networks:
# - frontend
# - backend
# ### CERTBOT ##################################
# # Exemplo de comando para rodas os certificados:
# # docker-compose run --rm certbot certonly --webroot --webroot-path /var/www/certbot/ --email [email protected] -d example.org
# # docker-compose run --rm certbot renew
# certbot:
# container_name: certbot
# image: certbot/certbot:latest
# volumes:
# - ${VOLUME_PATH}/certbot/www/:/var/www/certbot/:rw
# - ${VOLUME_PATH}/certbot/conf/:/etc/letsencrypt/:rw
# networks:
# - frontend
# - backend