# Is there a way to have multiple yaml configs?

**URL:** <https://discuss.elastic.co/t/is-there-a-way-to-have-multiple-yaml-configs/305363>\
**Category:** Elastic Cloud on Kubernetes (ECK)\
**Created:** [May 23, 2022, 1:50am UTC](https://discuss.elastic.co/t/is-there-a-way-to-have-multiple-yaml-configs/305363 "2022-05-23T01:50:40Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![anon17386273](https://avatars.discourse-cdn.com/v4/letter/a/d2c977/32.png) [@anon17386273](https://discuss.elastic.co/u/anon17386273)\
**Post date:** [May 23, 2022, 1:50am UTC](https://discuss.elastic.co/t/is-there-a-way-to-have-multiple-yaml-configs/305363/1 "2022-05-23T01:50:40Z")

</div>

Hi

I have successfully deployed a HOT-WARM environment using one ECK yaml config file.  
Lets say i decided to add COLD tier, is it possible to have a separate yaml config that joins the existing ECK cluster?

What is the best method in doing this? kubectl replace? or kubectl delete & re-apply?

Any help is appreciated. thank you!

---

<div class="post-metadata">

**Author:** ![legoguy1000](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/legoguy1000/32/54301_2.png) [@legoguy1000](https://discuss.elastic.co/u/legoguy1000)\
**Post date:** [May 23, 2022, 1:25pm UTC](https://discuss.elastic.co/t/is-there-a-way-to-have-multiple-yaml-configs/305363/2 "2022-05-23T13:25:33Z")

</div>

U want a single yaml to create a single Elasticsearch resource will multiple node sets with different roles

---

<div class="post-metadata">

**Author:** ![anon17386273](https://avatars.discourse-cdn.com/v4/letter/a/d2c977/32.png) [@anon17386273](https://discuss.elastic.co/u/anon17386273)\
**Post date:** [May 24, 2022, 1:48am UTC](https://discuss.elastic.co/t/is-there-a-way-to-have-multiple-yaml-configs/305363/3 "2022-05-24T01:48:29Z")

</div>

I want to know if it is possible to have multiple yaml to create a single Elasticsearch cluster

---

<div class="post-metadata">

**Author:** ![framsouza](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/framsouza/32/95958_2.png) [@framsouza](https://discuss.elastic.co/u/framsouza)\
**Post date:** [May 24, 2022, 1:13pm UTC](https://discuss.elastic.co/t/is-there-a-way-to-have-multiple-yaml-configs/305363/4 "2022-05-24T13:13:33Z")

</div>

Yes, at the moment you should use a single manifest to declare Elasticsearch resource. but you can use YAML anchors to remove some duplication if certain parts appear more than once.

or you can play with [Declarative Management of Kubernetes Objects Using Kustomize | Kubernetes](https://kubernetes.io/docs/tasks/manage-kubernetes-objects/kustomization/) which let you assemble final yaml file from the set of small ones

---

<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 21, 2022, 1:13pm UTC](https://discuss.elastic.co/t/is-there-a-way-to-have-multiple-yaml-configs/305363/5 "2022-06-21T13:13:34Z")

</div>

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