

All email services have vendor lock-in unless your using your own domain.
For what it is worth, I just moved my mail from my ISP to my own domain at a hosting service after 30 years. Took about 5 months to get everything changed but if I can do it anyone can.
Downside, using your own domain is probably less private but kind of depends.
Linux only, SSH works fine. Not e2ee. Nextcloud works fine but extra work unless you use a service provider. It can be e2ee but not normally so. Syncthing worth a look too. It is not cloud storage, but direct device transfer. Bitwarden send is useful too if you want to juat send file someone, and thunderbird is working on thunderbird send which might be interesting.
Maybe Synology if you want your own lan NAS?