Cloud services are very popular and the offer is big.
Not all your data you want to save on thirt-party servers. So, then you can use own cloud service on your server.
This tutorial will be working on Banana Pi M2 Berry (SBC with SATA interface), but the tutorial is the same for another SBC like Raspberry Pi, Orange Pi or Nano Pi.