# Index mapping at startup

**URL:** <https://discuss.elastic.co/t/index-mapping-at-startup/260741>\
**Category:** Elasticsearch\
**Created:** [January 11, 2021, 3:33pm UTC](https://discuss.elastic.co/t/index-mapping-at-startup/260741 "2021-01-11T15:33:03Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![hyunsoo](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/hyunsoo/32/82045_2.png) [@hyunsoo](https://discuss.elastic.co/u/hyunsoo)\
**Post date:** [January 11, 2021, 3:33pm UTC](https://discuss.elastic.co/t/index-mapping-at-startup/260741/1 "2021-01-11T15:33:03Z")

</div>

Hi all,

This question is about launching elasticsearch with kubernetes.  
If I run k8s like below,

```auto
...
containers:
      - name: elasticsearch
        image: docker.elastic.co/elasticsearch/elasticsearch:7.10.1
        ports:
          - containerPort: 9200
        env:
        - name: discovery.type
          value: single-node
...

```

Elasticsearch will be launched but there is no point that I can config something like index mapping.  
How can I set my index mapping at startup? Is there a tip related to this?

Thank you 🙂

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [January 12, 2021, 7:22am UTC](https://discuss.elastic.co/t/index-mapping-at-startup/260741/2 "2021-01-12T07:22:25Z")

</div>

Welcome to our community! 😃

Index mapping needs to happen via the Elasticsearch APIs. I am not sure if kubernetes can handle that for you sorry.

---

<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:** [February 9, 2021, 7:22am UTC](https://discuss.elastic.co/t/index-mapping-at-startup/260741/3 "2021-02-09T07:22:36Z")

</div>

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