Loggly plugin for Fluentd

Gem Gem Version

With fluent-plugin-loggly you will be able to use Loggly as output the logs you collect with Fluentd.

Getting Started

Note that buffered plugin uses bulk import to improve performance, so make sure to set Bulk endpoint to loggly_url.

The xxx-xxxx... is your Loggly access token.

Parameters

loggly_url the url to your loggly input (string).

Annotations

If you're running on Kubernetes you can use annotations to redirect logs to alternate Loggly URLs.

Simply enable the fluent-plugin-kubernetes_metadata_filter gem in your Fluentd setup and configure it to match annotations on the namespace and pod:

<filter kubernetes.**>
  type kubernetes_metadata
  include_namespace_metadata true
  annotation_match ["solarwinds.io/*"]
</filter>

Then add the following annotation to each namespace or pod that you'd like to redirect logs for:

solarwinds.io/loggly_url: 'https://logs-01.loggly.com/inputs/xxx-xxxx-xxxx-xxxxx-xxxxxxxxxx'

If both a pod and the namespace it's in have this annotation, the pod's annotation takes precedence.