Better Stack Docker logging

Want traces without code changes?

Install the Better Stack collector instead. It sends logs, metrics and eBPF traces from your Docker hosts with one command. This page sets up Vector for a Docker source.

Start logging in 2 minutes

Collect logs and metrics from your Docker containers using Vector.

Select your platform:

1. Setup

Install and configure Vector on Ubuntu or Debian:

Set up Vector
curl -sSL https://telemetry.betterstack.com/setup-vector/docker/$SOURCE_TOKEN \
  -o /tmp/setup-vector.sh && \
  bash /tmp/setup-vector.sh


Curious about what the script does?

  • Installs Vector using official package.
  • Configures Vector for your Better Stack source.
  • Enables and restarts Vector.

The script will ask for confirmation before making any changes.

2. Grant permissions

Allow Vector to access Docker logs:

Grant Vector permissions
usermod -a -G docker vector

You should see your logs in Better Stack β†’ Live tail.

Check out your metrics in the Docker dashboard.

No logs coming in?

Make sure that Vector has all necessary permissions. Run usermod -aG docker vector && service vector restart to add Vector user to the docker group and restart Vector right away.

Need help?

Please let us know at hello@betterstack.com.
We're happy to help! πŸ™

Additional information