<h1>Background</h1>
<p>I'm installing Elastic Search into my cluster with a helm chart with the following command:</p>
<pre class="lang-bash prettyprint-override"><code>helm -n elasticsearch upgrade --install -f values_elasticsearch.yaml  elasticsearch elastic/elasticsearch
</code></pre>
<p>This allows me to override the values which is nice, but I'd also like to add an <a href="https://istio.io/latest/docs/reference/config/networking/virtual-service/" rel="nofollow noreferrer">Istio virtual service</a>. Which I believe would require I add a template to the helm chart.</p>
<h2>Options</h2>
<p>I've considered the following thee options, but not sure what is best practice.</p>
<ol>
<li>Download the elastic search maintained helm chart and add a template for the additional yamls I need. This could create an issue when they upgrade their helm, I'm gonging to have to keep merging in their changes.</li>
<li>Add the template to a separate helm chart. I don't love this solution because I like to have one helm chart for a single namespace and application.</li>
<li>Create a helm subchart. I don't know much about these or if this is the right scenario to use them in.</li>
</ol>
<p>So I'm wondering if there is a better way to do this or which of my options is best.</p>

<p>helm subchart is ideal way</p>
<ul>
<li>You can create a helm chart and add the elasticsearch as subchart</li>
<li>You can add required istio yaml files inside your template folder</li>
<li>First you should run <code>helm dep update</code> then run the install/upgrade command</li>
</ul>
