loft-sh / devpod

Codespaces but open-source, client-only and unopinionated: Works with any IDE and lets you use any cloud, kubernetes or just localhost docker.
https://devpod.sh
Mozilla Public License 2.0
8.95k stars 337 forks source link

Kubernetes driver: additional volume support #534

Closed titilambert closed 1 year ago

titilambert commented 1 year ago

I want my devpods mount a local hostpath or a NFS volume in addition of the volume used by the workspace. I didn't see any way to configure that.

Where should be the right place ? in the provider config ? or in the .devcontainer.json file ?

Is your feature request related to a problem? No

Which solution do you suggest? Addition a way to add more volumes (and volumeMounts) in the kubernetes provider/driver settings or in the customizations section of the .devcontainer.json file

Which alternative solutions exist? Using Kubernetes mutating webhook (or something like kyverno) which can edit the pod settings before is actually created. Which is not an easy solution

Additional context I can see some other not supported settings of the pod manifest that I would like to change (like the toleration) Do you think it could be better to have a way to provide a template to devpod ? (instead of the current "mostly hard-coded" way? See: https://github.com/loft-sh/devpod/blob/784c84b783c0d580068d9dd0009c120272c282d3/pkg/driver/kubernetes/run.go#L158-L200

Thanks for your answers !

titilambert commented 1 year ago

Toleration is requested there https://github.com/loft-sh/devpod/issues/401