Created
April 14, 2020 08:44
-
-
Save wardbekker/ff87b7bb389d5f4384e5143e766423fc to your computer and use it in GitHub Desktop.
Fluent-Bit example configuration for Loki
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[INPUT] | |
Name tail | |
Path /var/log/*.log | |
Path_Key filename | |
[Output] | |
Name loki | |
Match * | |
Url http://localhost:3100/loki/api/v1/push | |
BatchWait 1 | |
BatchSize 3104304 | |
Labels {job="varlogs",host="ward_workstation",agent="fluent-bit"} | |
LabelKeys filename |
my config on name loki doesn't know url so am not allowed to put url in the config file
Indeed, probably things changed meanwhile. In 2023, "loki" output refers to fluent-bit version from https://docs.fluentbit.io/manual/pipeline/outputs/loki which uses Host
and Port
.
To make it work with Url
, should use instead "grafana-loki" as Name
for the output type, which corresponds to fluent-bit-plugin-loki flavour from Grafana. See https://github.com/grafana/loki/blob/main/clients/cmd/fluent-bit/fluent-bit.conf
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
my config on name loki doesn't know url so am not allowed to put url in the config file