3

Is there an official Docker image for Elastic Filebeat?

I see there are some community contributed ones, not sure if there is an official one.

A J
  • 2,508
  • 21
  • 26
Sahas
  • 3,046
  • 6
  • 32
  • 53

1 Answers1

11

Information about the official Docker images for Elastic Beats can be found at https://www.docker.elastic.co/r/beats/filebeat. The images are hosted in Elastic's container registry and not Docker Hub.

You can use the image with a command like:

docker run -v /var/log:/mnt/log docker.elastic.co/beats/filebeat:8.9.1

Or you can build your own image with customized config using a Dockerfile like:

FROM docker.elastic.co/beats/filebeat:8.9.1
COPY filebeat.yml /usr/share/filebeat/filebeat.yml

The images' source can be found at https://github.com/elastic/beats/tree/main/dev-tools/packaging/templates/docker.

A J
  • 2,508
  • 21
  • 26
  • I want to modify the entrypoint on this docker image, but I can't seem to locate the Dockerfile to modify it. – DomenicDatti Nov 01 '17 at 15:48
  • 1
    The Dockerfile is generated from a [template](https://github.com/elastic/beats-docker/blob/e766a426dc345768ca9abba1f004770366642911/templates/Dockerfile.j2#L49). If clone the repo, checkout the specific version you are interested in, then run `make` it will generate the Dockerfiles for each Beat. But you shouldn't need the original Dockerfile to change the `ENTRYPOINT` since you can overwrite it in your own Dockerfile. – A J Nov 01 '17 at 17:59