-
Notifications
You must be signed in to change notification settings - Fork 0
/
compose-infra.yml
100 lines (93 loc) · 2.23 KB
/
compose-infra.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
version: "3.9"
networks:
default:
name: monitoring-network
volumes:
minio:
mimir-1-data:
mimir-2-data:
minio-data:
services:
minio:
image: minio/minio
container_name: minio
entrypoint:
- sh
- -euc
- |
mkdir -p /data/loki && \
minio server --address 0.0.0.0:9000 --console-address 0.0.0.0:9001 /data
environment:
# the default
- MINIO_ROOT_USER=loki
- MINIO_ROOT_PASSWORD=supersecret
- MINIO_PROMETHEUS_AUTH_TYPE=public
ports:
- 9004:9000
- 9006:9001
volumes:
- minio:/data
# healthcheck:
# test: [ "CMD", "curl", "-f", "http://localhost:9000/minio/health/live" ]
# interval: 15s
# timeout: 20s
# retries: 5
labels:
logging: "promtail"
logging_jobname: "containerlogs"
loki-gateway:
image: nginx
container_name: loki-gateway
volumes:
- ./loki-nginx/nginx.conf:/etc/nginx/nginx.conf
ports:
- "8080:80"
- "3100"
depends_on:
- loki-read
- loki-write
# labels:
# logging: "promtail"
# logging_jobname: "containerlogs"
loki-read:
image: grafana/loki:2.9.1
container_name: loki-read
volumes:
- ./loki:/etc/loki/
ports:
- "3100"
- "7946"
# uncomment to use interactive debugging
# - "40000-40002:40000" # # makes the replicas available on ports 40000, 40001, 40002
#cap_add:
# - SYS_PTRACE
#security_opt:
# - apparmor=unconfined
command: "-config.file=/etc/loki/loki-config.yml -target=read"
restart: unless-stopped
# deploy:
# mode: replicated
# replicas: 3
depends_on:
- minio
loki-write:
image: grafana/loki:2.9.1
container_name: loki-write
volumes:
- ./loki:/etc/loki/
ports:
- "3100"
- "7946"
# uncomment to use interactive debugging
# - "50000-50002:40000" # makes the replicas available on ports 50000, 50001, 50002
# cap_add:
# - SYS_PTRACE
# security_opt:
# - apparmor=unconfined
command: "-config.file=/etc/loki/loki-config.yml -target=write"
restart: unless-stopped
# deploy:
# mode: replicated
# replicas: 3
depends_on:
- minio