Authenticate against locally mounted nfs filesystem

Hello Nextclouders,

I’m administrating a Nextcloud 21 instance running on Ubuntu 21 with ~700 users. Files are located on a seperate linux vm which hosts all users via LDAP. Nextcloud authentication against LDAP works fine, user-specific shares are mounted via external storages with the smb/cifs-connector.
However accessing files via nfs would increase performance compared to the use of smb. Therefore I configured local Ubuntu pam authentication against LDAP and mounted the user-shares via nfs. Now I am able to authenticate local Ubuntu users against LDAP, user permissions are correctly mapped and the shares mounted via nfs are treated on the Nextcloud-vm inside Ubuntu the same way they are treated on the separate linux vm. Great so far.
But unfortunately Nextcloud itself fullfills read-write-operations on local files as the www-data user - even when using the external-storage-app with the option “local”
Is it somehow possible to make Nextcloud perform local file operations with the credentials of the actually logged-in Nextcloud-user?
Any ideas appreciated :slight_smile: