<p>I'm creating an application that is using helm(v3.3.0) + k3s. A program in a container uses different configuration files. As of now there are just few config files (that I added manually before building the image) but I'd like to add the possibility to add them dynamically when the container is running and not to lose them once the container/pod is dead. In docker I'd do that by exposing a folder like this:</p>
<p><code>docker run [image] -v /host/path:/container/path</code></p>
<p>Is there an equivalent for helm?
If not how would you suggest to solve this issue without stopping using helm/k3s?</p>

<p>In Kubernetes (Helm is just a tool for it) you need to do two things to mount host path inside container:</p>
<pre class="lang-yaml prettyprint-override"><code>spec:
  volumes:
  # 1. Declare a 'hostPath' volume under pod's 'volumes' key:
  - name: name-me
    hostPath:
      path: /path/on/host
  containers:
  - name: foo
    image: bar
    # 2. Mount the declared volume inside container using volume name
    volumeMounts:
    - name: name-me
      mountPath: /path/in/container
</code></pre>
<p>Lots of other volumes types and examples in Kubernetes <a href="https://kubernetes.io/docs/concepts/storage/volumes" rel="nofollow noreferrer">documentation</a>.</p>
