Moving Database to external USB drive


for testing purposes i’ve installed Nextcloud on a Raspberry with Ubuntu 20.04 Server (64-bit) on it, so far it works perfect with very good performance on the 4GB device

As far as i understand NextCloudPI does not work on this architecture, so i will be missing the nextcloud panel with the features like Snapshots etc.

Not a problem at all, but i like the feature to move not only the data but also the database to the external drive. Would like to do this here as well to reduce write attempts to SD card.

How do i do this without having NCP installed?