# Include part(s) of configuration in conf file

**URL:** https://discuss.elastic.co/t/include-part-s-of-configuration-in-conf-file/151851
**Category:** Logstash
**Created:** [October 10, 2018, 1:12pm UTC](https://discuss.elastic.co/t/include-part-s-of-configuration-in-conf-file/151851 "2018-10-10T13:12:15Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![parosio](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/parosio/32/27367_2.png) [@parosio](https://discuss.elastic.co/u/parosio)
#### Post date: [October 10, 2018, 1:12pm UTC](https://discuss.elastic.co/t/include-part-s-of-configuration-in-conf-file/151851/1 "2018-10-10T13:12:15Z")

</div>

Hello,  
I'm aware it's possible to have logstash configured with a merge of different files found in a directory, but I've got a rather different structure for input files (and, consequently, for configurations).

Nevertheless, there are some tasks wich are common, and could be reused as-is in different configuration files.

I wish it'd be possible to have such chunck of configuration (for example the geolocalization of IP addresses) in a separate file and include them in the actual configuration files only when needed.

Is there anything to accomplish this?

---

<div class="post-metadata">

### Author: ![parosio](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/parosio/32/27367_2.png) [@parosio](https://discuss.elastic.co/u/parosio)
#### Post date: [October 19, 2018, 1:20pm UTC](https://discuss.elastic.co/t/include-part-s-of-configuration-in-conf-file/151851/2 "2018-10-19T13:20:07Z")

</div>

As often happens, the answer was in the man:

[https://www.elastic.co/guide/en/logstash/6.4/running-logstash-command-line.html#command-line-flags](https://www.elastic.co/guide/en/logstash/6.4/running-logstash-command-line.html#command-line-flags)

it's enough to put the configuration filenames in the same -f option:

`bin/logstash --debug -f '/tmp/{one,two,three}'`

---

<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: [November 16, 2018, 1:20pm UTC](https://discuss.elastic.co/t/include-part-s-of-configuration-in-conf-file/151851/3 "2018-11-16T13:20:09Z")

</div>

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