# Filebeat autodiscover for local log Docker driver

**URL:** <https://discuss.elastic.co/t/filebeat-autodiscover-for-local-log-docker-driver/278878>\
**Category:** Beats\
**Tags:** docker, filebeat\
**Created:** [July 16, 2021, 10:21am UTC](https://discuss.elastic.co/t/filebeat-autodiscover-for-local-log-docker-driver/278878 "2021-07-16T10:21:01Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![llsousa](https://avatars.discourse-cdn.com/v4/letter/l/dfb087/32.png) [@llsousa](https://discuss.elastic.co/u/llsousa)\
**Post date:** [July 16, 2021, 10:21am UTC](https://discuss.elastic.co/t/filebeat-autodiscover-for-local-log-docker-driver/278878/1 "2021-07-16T10:21:01Z")

</div>

Hi, there, first post here.

Suppose this Filebeat autodiscover configuration for Docker containers:

```auto
filebeat.autodiscover:
  providers:
    - type: docker
      hints.enabled: true
      hints.default_config.enabled: false

```

This config works like a cham if using default Docker json-log driver, that is, it harvests the files from `/var/lib/docker/containers/*/*-json.log`.

Docker still uses the default json-log driver for backward compatibility, but [recommends local log driver for performance and rotate features](https://docs.docker.com/config/containers/logging/configure/).

In practice, the logs change format and are moved from `/var/lib/docker/containers/*/*-json.log` to `/var/lib/docker/containers/*/local-logs/container.log`.

This can be configured changing `hints.default_config` to:

```auto
      hints.default_config:
        type: container
        paths:
          - /var/log/containers/${data.container.id}/local-log/container.log

```

This new file isn't in JSON format and isn't parsed.

Is it possible to use local log Docker driver with autodiscover?

Best regards,  
Luís Sousa

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [August 13, 2021, 12:21pm UTC](https://discuss.elastic.co/t/filebeat-autodiscover-for-local-log-docker-driver/278878/2 "2021-08-13T12:21:06Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
