Setting up primary storage on NFS share during install

I original installed an appliance version of nextcloud on my proxmox server but I want to store the data on a NAS rather than inside the next cloud appliance. I found posts on how to do this, but they say its not recommended and to do a new install instead.

So I setup a new VM with ubuntu and while it was installing it gave the choice to install a nextcloud package. After that was done I never saw a choice to change the primary data directory so I am back to square 1 again. How can I setup nextcloud so it uses the NFS share as its data directory from the beginning.

I am a noob when it comes to linux so I may be missing something.

Thanks for any help!

You have to mount the nfs-share before the installation. While the installation, choose your mountpoint as data-datadirectory.

Make sure, you have entered your nfs into fstab.