How to add a plugin to ELK in a docker-compose file?

Hello everyone, i have an important question.

If I would like to add a logstash plugin to my docker-compose file, how I could do it?

This is the section of logstash I have in my docker-compose (it's not working because the pipeline I'm running needs the plugin "date_formatter") :

#Logstash container
container_name: logstash
hostname: logstash
- ./config/logstash/logstash.yml:/usr/share/logstash/config/logstash.yml:ro
- ./config/logstash/pipeline:/usr/share/logstash/pipeline/
- ./.kitchen/logs:/logs
command: /usr/share/logstash/bin/logstash/logstash-plugin install logstash-filter-date_formatter
#Port 5044 accessible on the host
ports: ['5044:5044']
networks: ['stack']
elasticsearch: { condition: service_healthy }
test: ["CMD", "curl", "-f", "http://localhost:9600"]
retries: 10
interval: 10s

Would you mind giving me some advice?

Thanks so much,

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