I use default nginx image and Filebeat to read logs and send them to ELK. Both containers (nginx container and Filebeat container) are on the same host machone.
Here is Dockerfile for nginx image
FROM nginx
COPY . /usr/share/nginx/html/
EXPOSE 80
In my nginx container access log goes to STDOUT
and error log goes to STDERR
.
When I prompt from host machine docker logs <nginx-containter-id>
I can see logs from nginx container.
But there is nothing in container's folder on host machine (/var/lib/docker/containers/nginx-container-id
)
how can set up filebeat to read logs?