Files
gitops/argocd-apps/add-ons/loki.yaml
T

130 lines
3.6 KiB
YAML

apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
annotations:
argocd.argoproj.io/client-side-apply-migration-manager: argocd-controller
argocd.argoproj.io/sync-wave: "4"
name: loki
namespace: argocd
spec:
destination:
namespace: monitoring
server: https://kubernetes.default.svc
project: default
sources:
- chart: loki
helm:
values: |
# Garage on 3900; the rules sidecar watches the API, which only the
# discovery port can allow
networkPolicy:
enabled: true
externalStorage:
ports:
- 3900
discovery:
port: 6443
loki:
auth_enabled: false
commonConfig:
replication_factor: 1
schemaConfig:
configs:
- from: "2026-09-01"
store: tsdb
object_store: s3
schema: v13
index:
prefix: loki_index_
period: 24h
storage:
bucketNames:
chunks: loki
ruler: loki
s3:
endpoint: http://garage.garage.svc.cluster.local:3900
region: garage
accessKeyId: ${LOKI_S3_ACCESS_KEY_ID}
secretAccessKey: ${LOKI_S3_SECRET_ACCESS_KEY}
s3ForcePathStyle: true
insecure: true
ingester:
chunk_encoding: zstd
compactor:
retention_enabled: true
delete_request_store: s3
limits_config:
retention_period: 2160h
singleBinary:
replicas: 1
extraEnvFrom:
- secretRef:
name: loki-s3
resources:
limits:
cpu: "1"
memory: 2Gi
requests:
cpu: 100m
memory: 512Mi
# Memory limits sit ~20% above memcached's allocation.
chunksCache:
allocatedMemory: 512
resources:
limits:
cpu: 500m
memory: 614Mi
requests:
cpu: 50m
memory: 614Mi
resultsCache:
allocatedMemory: 128
resources:
limits:
cpu: 500m
memory: 154Mi
requests:
cpu: 50m
memory: 154Mi
memcachedExporter:
resources:
limits:
cpu: 100m
memory: 64Mi
requests:
cpu: 10m
memory: 16Mi
sidecar:
resources:
limits:
cpu: 100m
memory: 256Mi
requests:
cpu: 10m
memory: 64Mi
# Grafana and Alloy talk to Loki directly, there is a single tenant.
gateway:
enabled: false
lokiCanary:
enabled: false
test:
enabled: false
backend:
replicas: 0
read:
replicas: 0
write:
replicas: 0
repoURL: https://grafana-community.github.io/helm-charts
targetRevision: 18.15.1
- path: add-ons/loki
repoURL: https://gitea.whyredfire.dev/whyredfire/gitops.git
targetRevision: main
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
- ServerSideApply=true