github.com/yankunsam/loki/v2@v2.6.3-0.20220817130409-389df5235c27/production/nomad/loki-simple/config.yml (about)

     1  auth_enabled: false
     2  
     3  server:
     4    log_level: info
     5    http_listen_port: {{ env "NOMAD_PORT_http" }}
     6    grpc_listen_port: {{ env "NOMAD_PORT_grpc" }}
     7  
     8  common:
     9    replication_factor: 1
    10    # Tell Loki which address to advertise
    11    instance_addr: {{ env "NOMAD_IP_grpc" }}
    12    ring:
    13      # Tell Loki which address to advertise in ring
    14      instance_addr: {{ env "NOMAD_IP_grpc" }}
    15      kvstore:
    16        store: consul
    17        prefix: loki/
    18        consul:
    19          host: {{ env "attr.unique.network.ip-address" }}:8500
    20  
    21  ingester:
    22    wal:
    23      dir: {{ env "NOMAD_ALLOC_DIR" }}/data/wal
    24      flush_on_shutdown: true
    25      replay_memory_ceiling: "1G"
    26  
    27  schema_config:
    28    configs:
    29    - from: 2022-05-15
    30      store: boltdb-shipper
    31      object_store: s3
    32      schema: v12
    33      index:
    34        prefix: index_
    35        period: 24h
    36  
    37  storage_config:
    38    boltdb_shipper:
    39      # Nomad ephemeral disk is used to store index and cache
    40      # it will try to preserve /alloc/data between job updates
    41      active_index_directory: {{ env "NOMAD_ALLOC_DIR" }}/data/index
    42      cache_location: {{ env "NOMAD_ALLOC_DIR" }}/data/index-cache
    43      shared_store: s3
    44  
    45    aws:
    46      endpoint: https://minio.service.consul
    47      bucketnames: loki
    48      region: us-west-1
    49      access_key_id: ${S3_ACCESS_KEY_ID}
    50      secret_access_key: ${S3_SECRET_ACCESS_KEY}
    51      s3forcepathstyle: true
    52  
    53  limits_config:
    54    enforce_metric_name: false
    55    reject_old_samples: true
    56    reject_old_samples_max_age: 168h
    57  
    58  compactor:
    59    working_directory: {{ env "NOMAD_ALLOC_DIR" }}/compactor
    60    shared_store: s3
    61    compaction_interval: 5m
    62    retention_enabled: true
    63  
    64  ruler:
    65    alertmanager_url: https://alertmanager.service.consul
    66    enable_alertmanager_v2: true
    67    enable_api: true
    68    external_url: https://loki.service.consul
    69    rule_path: {{ env "NOMAD_ALLOC_DIR" }}/tmp/rules
    70    storage:
    71      type: local
    72      local:
    73        directory: {{ env "NOMAD_TASK_DIR" }}/rules
    74    wal:
    75      dir: {{ env "NOMAD_ALLOC_DIR" }}/data/ruler