Mount folder using SSH in Kubernetes / Azure

245 Views Asked by At

I'm able to mount a folder using SSH when I run my docker container locally (outside Kubernetes/Azure):

docker volume create --driver vieux/sshfs -o sshcmd=[user]@[IP]:/location_on_server -o password=[password] -o allow_other ssh_share

docker run -d -v ssh_share:/location_in_container my_image

How can I do the same in Azure / Kubernetes? What should I put into the deployment yaml / or maybe there is some workaround?

I found this solution https://github.com/chr-fritz/csi-sshfs but I can't use it on production since it's in an experimental stage.

If this is not possible or recommended using SSHFS, what's the easiest solution in which the files will stay on the same remote linux server?

0

There are 0 best solutions below