Star us on GitHub
Star
Menu

Docker / Docker Compose

Ship docker logs to highlight using the fluentd log driver.
1
Setup the fluentd log driver.

Use the Fluentd logging driver to route logs to highlight.

docker run --log-driver=fluentd --log-opt fluentd-address=otel.highlight.io:24224 --log-opt tag=highlight.project_id=<YOUR_PROJECT_ID> -t ubuntu echo "Testing a log message"
Copy
2
Setup the fluentd log driver in docker compose.

Use the following syntax if you are using docker compose.

x-logging: &highlight-logging driver: fluentd options: fluentd-address: "otel.highlight.io:24224" fluentd-async: "true" fluentd-sub-second-precision: "true" tag: "highlight.project_id=<YOUR_PROJECT_ID>" services: example: logging: *highlight-logging image: ubuntu container_name: ubuntu command: - echo - "hello, highlight.io!"
Copy
3
Verify your backend logs are being recorded.

Visit the highlight logs portal and check that backend logs are coming in.