auth_enabled: false

server:
  http_listen_port: 3100
  grpc_listen_port: 9096
  grpc_server_max_recv_msg_size: 16777216
  grpc_server_max_send_msg_size: 16777216

common:
  path_prefix: /loki
  replication_factor: 1
  ring:
    kvstore:
      store: inmemory
  storage:
    filesystem:
      chunks_directory: /loki/chunks
      rules_directory: /loki/rules

schema_config:
  configs:
    - from: 2024-01-01
      store: tsdb
      object_store: filesystem
      schema: v13
      index:
        prefix: index_
        period: 24h

storage_config:
  filesystem:
    directory: /loki/chunks
  tsdb_shipper:
    active_index_directory: /loki/tsdb-index
    cache_location: /loki/tsdb-cache

compactor:
  working_directory: /loki/compactor
  compaction_interval: 10m
  retention_enabled: true
  delete_request_store: filesystem

limits_config:
  # Increase ingestion limits to avoid 429 during backlog flush
  ingestion_rate_mb: 20
  ingestion_burst_size_mb: 40
  # Disable auto log-level detection (prevents detected_level label)
  discover_log_levels: false
  reject_old_samples: true
  reject_old_samples_max_age: 168h
  retention_period: 168h   # 7d

frontend:
  grpc_client_config:
    max_recv_msg_size: 16777216
    max_send_msg_size: 16777216

frontend_worker:
  query_frontend_grpc_client:
    max_recv_msg_size: 16777216
    max_send_msg_size: 16777216

ruler:
  storage:
    type: local
    local:
      directory: /loki/rules
  rule_path: /loki/rules-temp
