# Automatically create "logstash-\*" as index pattern for Kibana

**URL:** https://discuss.elastic.co/t/automatically-create-logstash-as-index-pattern-for-kibana/84221
**Category:** Kibana
**Created:** [May 2, 2017, 8:36am UTC](https://discuss.elastic.co/t/automatically-create-logstash-as-index-pattern-for-kibana/84221 "2017-05-02T08:36:16Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Pat92](https://avatars.discourse-cdn.com/v4/letter/p/8e7dd6/32.png) [@Pat92](https://discuss.elastic.co/u/Pat92)
#### Post date: [May 2, 2017, 8:36am UTC](https://discuss.elastic.co/t/automatically-create-logstash-as-index-pattern-for-kibana/84221/1 "2017-05-02T08:36:16Z")

</div>

Hi all ,  
I'm using the elatic stack ( logstash 5.3.0 , kibana 5.3.0 and elasticsearch 5.3.0) with Docker  
I'm running a test environment where all the Docker containers are being removed and recreated automatically every day . So every time you have to recreate the " logstash-\* " index  
So is there a solution to make logstash-\* the default index ?  
Even the elasticsearch container is being removed every day so i can't use :  
curl -XPUT http://ip\_address:9200/.kibana/index-pattern/logstash-\* -d '{"title" : "logstash-_", "timeFieldName": "@timestamp"}'  
curl -XPUT http://ip\_address:9200/.kibana/config/5.3.0 -d '{"defaultIndex" : "logstash-_"}'

---

<div class="post-metadata">

### Author: ![tylersmalley](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tylersmalley/32/8833_2.png) [@tylersmalley](https://discuss.elastic.co/u/tylersmalley)
#### Post date: [May 3, 2017, 5:22pm UTC](https://discuss.elastic.co/t/automatically-create-logstash-as-index-pattern-for-kibana/84221/2 "2017-05-03T17:22:16Z")

</div>

Why not persist the elasticsearch data by mounting a volume?

---

<div class="post-metadata">

### Author: ![Pat92](https://avatars.discourse-cdn.com/v4/letter/p/8e7dd6/32.png) [@Pat92](https://discuss.elastic.co/u/Pat92)
#### Post date: [May 8, 2017, 10:13am UTC](https://discuss.elastic.co/t/automatically-create-logstash-as-index-pattern-for-kibana/84221/3 "2017-05-08T10:13:22Z")

</div>

Yes , thank you . it work

---

<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: [June 5, 2017, 10:20am UTC](https://discuss.elastic.co/t/automatically-create-logstash-as-index-pattern-for-kibana/84221/4 "2017-06-05T10:20:52Z")

</div>

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