[Kubernetes] Install Loki(v2.9.4) Stack Using Helm Chart

Helm 설치 및 설명 참고 {: .prompt-info }

Install the Loki Stack Helm charts #

1helm repo add grafana https://grafana.github.io/helm-charts
2helm repo update
3helm install loki-stack grafana/loki-stack --namespace [NAMESPACE NAME] --version [VERSION]

Loki Stack - Helm 설치 참고

Customize Default Configuration #

Setting Promtail #

1promtail:
2  enabled: true
3  config:
4    logLevel: info
5    serverPort: 3101
6    clients:
7      - url: http://{{ .Release.Name }}:3100/loki/api/v1/push

Promtail 설치 및 설정 관련 참고 {: .prompt-info }

Setting Loki #

 1loki:
 2  enabled: true
 3  isDefault: true
 4  url: http://{{(include "loki.serviceName" .)}}:{{ .Values.loki.service.port }}
 5  readinessProbe:
 6    httpGet:
 7      path: /ready
 8      port: http-metrics
 9    initialDelaySeconds: 45
10  livenessProbe:
11    httpGet:
12      path: /ready
13      port: http-metrics
14    initialDelaySeconds: 45
15  datasource:
16    jsonData: "{}"
17    uid: ""

Loki 관련 참고 {: .prompt-info }

Setting Grafana #

 1grafana:
 2  enabled: false
 3  sidecar:
 4    datasources:
 5      label: ""
 6      labelValue: ""
 7      enabled: true
 8      maxLines: 1000
 9  image:
10    tag: 10.3.3

Grafana 설치 및 설정 관련 참고 {: .prompt-info }

Install Customize Default Configuration #

1helm install [RELEASE NAME] [Chart.yaml 경로] -f [YAML 파일 또는 URL에 값 지정 (여러 개를 지정가능)] -n [NAMESPACE NAME]
1helm install loki-stack grafana/loki-stack -f override-values.yaml -n [NAMESPACE NAME]

Uninstall the Chart #

1helm uninstall [RELEASE NAME] -n [NAMESPACE NAME]
Advertisement