FEAT(loki): configure storage and HA

- Rename extraVolume to avoid duplicate name
- Add emptyDir for /var/loki cache
- Migrate to shared storage with MinIO
- Configure HA with 2 replicas
- Revert to single replica for Single Binary mode
This commit is contained in:
2026-01-08 13:37:22 +09:00
parent 1b7a4294dc
commit 2b7ee1fe51
5 changed files with 65 additions and 14 deletions

View File

@@ -27,3 +27,4 @@ spec:
managedNamespaceMetadata:
labels:
goldilocks.fairwinds.com/enabled: 'true'
minio-s3: enabled

View File

@@ -1,22 +1,35 @@
# Loki Helm Values
# Chart: https://grafana.github.io/helm-charts
# Simple single binary deployment
# Single binary deployment with S3 (MinIO) storage
loki:
# Use filesystem storage (simple setup)
# Use S3 storage (MinIO)
storage:
type: filesystem
type: s3
s3:
endpoint: http://minio.minio.svc.cluster.local:9000
region: us-east-1
bucketNames:
chunks: loki
ruler: loki
admin: loki
s3ForcePathStyle: true
insecure: true
bucketNames:
chunks: loki
ruler: loki
admin: loki
# Single binary mode for simplicity
commonConfig:
replication_factor: 1
# Schema config
schemaConfig:
configs:
- from: "2024-01-01"
store: tsdb
object_store: filesystem
object_store: s3
schema: v13
index:
prefix: index_
@@ -37,18 +50,23 @@ deploymentMode: SingleBinary
singleBinary:
replicas: 1
# Note: Single Binary mode cannot run more than 1 replica without object storage backend
persistence:
enabled: true
size: 5Gi # Reduced from 10Gi to save storage
storageClass: local-path
enabled: false
extraEnvFrom:
- secretRef:
name: minio-s3-credentials
extraVolumes:
- name: tmp
emptyDir: {}
extraVolumeMounts:
- name: tmp
mountPath: /var/loki
resources:
requests:
cpu: 23m
memory: 462Mi
limits:
memory: 462Mi
# Note: Affinity not needed for single replica
# Disable components not needed in single binary mode
backend: