Docker Swarm logging
Deploy fluent-bit container
parsers.conf
[PARSER]
Name json
Format jsonfluent-bit.conf
[SERVICE]
Flush 1
Parsers_File /fluent-bit/etc/parsers.conf
Log_Level error
# collect docker logs using fluend logging driver
[INPUT]
Name forward
Listen 0.0.0.0
port 24224
# try parsing log as json and lift its keys to the first-level
[FILTER]
Name parser
Match *
Parser json
Key_Name log
Reserve_Data On
[OUTPUT]
name http
match *
host <Apica-Ascent-endpoint>
port 443
URI /v1/json_batch
Format json
tls on
tls.verify off
net.keepalive off
compress gzip
Header Authorization Bearer <Token>docker-compose.fluent.yaml
Update services to add logging driver
Examples
Last updated
Was this helpful?