Hey Ho, quite the beginner here, I am using RancherOS for homelab use.
In previous versions I mounted my NFS shares to different folders in RancherOS/mnt/ using the nfs client, my nfs.yml looked like this, and it worked just fine. In my containers i just added volumes /mnt/data:/mnt/data and so on
#/var/lib/rancher/conf/cloud-config.d/nfs.yml write_files: - path: /etc/rc.local permissions: "0755" content: | #!/bin/bash [ ! -e /usr/bin/docker ] && ln -s /usr/bin/docker.dist /usr/bin/docker rancher: services: nfs: image: d3fk/nfs-client labels: io.rancher.os.after: console, preload-user-images io.rancher.os.scope: system net: host privileged: true restart: always volumes: - /usr/bin/iptables:/sbin/iptables:ro - /mnt/data:/mnt/data:shared - /mnt/data2:/mnt/data2:shared environment: SERVER: 192.168.0.2 SHARE: /mnt/volume01/data MOUNTPOINT: /mnt/data #cloud-config mounts: - ["192.168.0.2:/mnt/volume02/data2", "/mnt/data2", "nfs", ""]
after setting up a new host i thought i’d try 1.5RC which installed quite quickly and easy. Great.
Now I wanted to mount my NFS shares and tried the same thing, which ultimately did not work. Then i noticed that normal sudo mount commands work perfectly fine. So here is my question if i’d like to mount an nfs share to my host how would i do it?
#workd out of the box sudo mount -o nfsvers=4,port=2049,nolock,proto=tcp -t nfs 192.168.0.2:/mnt/volume01/data /mnt/data