-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
89 lines (84 loc) · 2.54 KB
/
docker-compose.yml
File metadata and controls
89 lines (84 loc) · 2.54 KB
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
services:
prometheus:
image: prom/prometheus:v2.54.1
container_name: obsv-prometheus
command:
- "--config.file=/etc/prometheus/prometheus.yml"
- "--storage.tsdb.path=/prometheus"
- "--storage.tsdb.retention.time=30d"
- "--storage.tsdb.retention.size=8GB"
ports:
- "9090:9090"
volumes:
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml:ro
- prometheus_data:/prometheus
security_opt:
- no-new-privileges:true
restart: unless-stopped
node-exporter:
image: prom/node-exporter:v1.8.2
container_name: obsv-node-exporter
command:
- "--path.rootfs=/host"
volumes:
- "/:/host:ro"
security_opt:
- no-new-privileges:true
restart: unless-stopped
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:8.15.0
container_name: obsv-elasticsearch
environment:
- discovery.type=single-node
- xpack.security.enabled=false
- ES_JAVA_OPTS=-Xms${ES_HEAP_SIZE:-512m} -Xmx${ES_HEAP_SIZE:-512m}
volumes:
- es_data:/usr/share/elasticsearch/data
healthcheck:
test: ["CMD-SHELL", "curl -s http://localhost:9200 >/dev/null || exit 1"]
interval: 15s
timeout: 5s
retries: 20
security_opt:
- no-new-privileges:true
restart: unless-stopped
fluent-bit:
image: cr.fluentbit.io/fluent/fluent-bit:3.2.2
container_name: obsv-fluent-bit
depends_on:
elasticsearch:
condition: service_healthy
volumes:
- ./fluent-bit/fluent-bit.conf:/fluent-bit/etc/fluent-bit.conf:ro
- ./fluent-bit/parsers.conf:/fluent-bit/etc/parsers.conf:ro
- ./sample-logs:/var/log/app:ro
- fluentbit_state:/fluent-bit/state
security_opt:
- no-new-privileges:true
restart: unless-stopped
grafana:
image: grafana/grafana:11.2.2
container_name: obsv-grafana
depends_on:
- prometheus
- elasticsearch
ports:
- "3300:3000"
environment:
- GF_SECURITY_ADMIN_USER=${GF_SECURITY_ADMIN_USER}
- GF_SECURITY_ADMIN_PASSWORD=${GF_SECURITY_ADMIN_PASSWORD}
- GF_USERS_ALLOW_SIGN_UP=false
- GF_SERVER_ROOT_URL=${GRAFANA_ROOT_URL}
- GF_SERVER_SERVE_FROM_SUB_PATH=${GRAFANA_SERVE_FROM_SUB_PATH}
volumes:
- grafana_data:/var/lib/grafana
- ./grafana/provisioning:/etc/grafana/provisioning:ro
- ./grafana/dashboards:/var/lib/grafana/dashboards:ro
security_opt:
- no-new-privileges:true
restart: unless-stopped
volumes:
prometheus_data:
es_data:
grafana_data:
fluentbit_state: