configure persisent storage

This commit is contained in:
2025-10-12 16:49:47 +02:00
parent 281af93e60
commit a40b4e8ef1
2 changed files with 31 additions and 39 deletions

View File

@@ -3,11 +3,12 @@ services:
image: grafana/loki:3.5.3 image: grafana/loki:3.5.3
container_name: loki container_name: loki
restart: always restart: always
user: root
ports: ports:
- "3100:3100" - "3100:3100"
# command: -config.file=/etc/loki/local-config.yaml command: -config.file=/etc/loki/local-config.yaml
# volumes: volumes:
# - /opt/loki/local-config.yaml:/etc/loki/local-config.yaml:ro - /opt/loki/local-config.yaml:/etc/loki/local-config.yaml:ro
# - /opt/loki/data:/loki - /opt/loki/data:/loki
extra_hosts: extra_hosts:
- host:192.168.2.200 - host:192.168.2.200

View File

@@ -1,46 +1,37 @@
auth_enabled: false
common:
replication_factor: 1
path_prefix: /loki
server: server:
http_listen_port: 3100 http_listen_port: 3100
http_server_read_timeout: 10m
http_server_write_timeout: 10m
http_server_idle_timeout: 10m
memberlist: ingester:
join_members: lifecycler:
- localhost:7946 ring:
kvstore:
limits_config: store: inmemory
per_stream_rate_limit: 0 final_sleep: 0s
chunk_idle_period: 5m
query_range: chunk_retain_period: 30s
split_queries_by_interval: 10m
cache_results: true
schema_config: schema_config:
configs: configs:
- from: 2021-08-01 - from: 2020-10-24
store: boltdb-shipper store: tsdb
object_store: s3 object_store: filesystem
schema: v11 schema: v13
index: index:
prefix: index_ prefix: index_
period: 24h period: 24h
common: storage_config:
path_prefix: /loki filesystem:
replication_factor: 1 directory: /loki/chunks
storage:
s3:
endpoint: host:9000
insecure: true
bucketnames: loki
access_key_id: loki
secret_access_key: vryrquhchbdzgfjmlyctrdjiibobhhxc
s3forcepathstyle: true
ring:
kvstore:
store: memberlist
ruler: limits_config:
storage: allow_structured_metadata: true
s3:
bucketnames: loki-ruler analytics:
reporting_enabled: false