diff --git a/config/templates/etc/filebeat/filebeat.yml.j2 b/config/templates/etc/filebeat/filebeat.yml.j2 index 357da508..86f1589b 100644 --- a/config/templates/etc/filebeat/filebeat.yml.j2 +++ b/config/templates/etc/filebeat/filebeat.yml.j2 @@ -71,6 +71,13 @@ filebeat.inputs: # Note: After is the equivalent to previous and before is the equivalent to to next in Logstash #multiline.match: after +{% if beats_config.filebeat.close_timeout is defined %} + # Close timeout closes the harvester after the predefined time. + # This is independent if the harvester did finish reading the file or not. + # By default this option is disabled. + # Note: Potential data loss. Make sure to read and understand the docs for this option. + close_timeout: {{ beats_config.filebeat.close_timeout }} +{% endif %} #============================= Filebeat modules ===============================