Lưu ý:
Thêm helm chart grafana
helm repo add grafana [<https://grafana.github.io/helm-charts>](<https://grafana.github.io/helm-charts>)
Chuẩn bị file value.yaml
loki:
schemaConfig:
configs:
- from: "2024-04-01"
store: tsdb
object_store: s3
schema: v13
index:
prefix: loki_index_
period: 24h
ingester:
chunk_encoding: snappy
tracing:
enabled: true
querier:
# Default is 4, if you have enough memory and CPU you can increase, reduce if OOMing
max_concurrent: 4
#gateway:
# ingress:
# enabled: true
# hosts:
# - host: FIXME
# paths:
# - path: /
# pathType: Prefix
deploymentMode: SimpleScalable
backend:
replicas: 3
read:
replicas: 3
write:
replicas: 3
# Enable minio for storage
minio:
enabled: true
# Zero out replica counts of other deployment modes
singleBinary:
replicas: 0
ingester:
replicas: 0
querier:
replicas: 0
queryFrontend:
replicas: 0
queryScheduler:
replicas: 0
distributor:
replicas: 0
compactor:
replicas: 0
indexGateway:
replicas: 0
bloomCompactor:
replicas: 0
bloomGateway:
replicas: 0
Cài đặt loki
helm upgrade -i --values values.yaml loki grafana/loki
Thêm helm chart prometheus
helm repo add prometheus-community <https://prometheus-community.github.io/helm-charts>
Cài đặt promentheus
helm install prometheus prometheus-community/prometheus