<p>Using helm I know you can disable a dependency in <strong>requirements.yaml</strong> using a <strong>condition</strong>.</p>

<p>However, I have a dependency copied into the <strong>charts/</strong> directory and expanded because I need more control over it.</p>

<p>Is there is any way to conditionally include this dependency given that it's not included via <strong>requirements.yaml</strong> but rather through expanding in the charts/ folder?</p>

<p>Yes, according to <a href="https://github.com/helm/helm/blob/master/docs/helm/helm_dependency.md" rel="nofollow noreferrer">helm dependency docs</a>:</p>

<blockquote>
  <p>Starting from <strong>2.2.0</strong>, repository can be defined as the path to the directory of the dependency charts stored locally. The path should start with a prefix of "file://". For example,</p>

<pre><code># requirements.yaml
dependencies:
- name: nginx
 version: "1.2.3"
 repository: "file://../dependency_chart/nginx"
</code></pre>
  
  <p>If the dependency chart is retrieved locally, it is not required to have the repository added to helm by "helm repo add". Version matching is also supported for this case.</p>
</blockquote>
