Yunohost on VPS, Data at Home - Thoughts?

I’ve been thinking of what to do with my server in the future. I currently run everything at home: old computer, RAID drives.

I am thinking in the future it might be good to have:

  • Yunohost on VPS
  • RAID with files at home
  • Wireguard connect VPS to RAID

Is anybody running something like this? (mixed VPS/home situation)

I’m doing so, with mixed complexity and mixed success.

What is the reason for you to go in this direction?

1 Like
  1. I am only exploring the possibility of it.

  2. Why am I thinking about this?
    VPS: very fast, great reliability, email might work better with correct rDNS etc.
    Home server: lots of cheap hard drive space, feel more secure about my important files specifically photos (photoprism)

I would like to have email working better and chat. It would be great to have a fast enough server to have Jitsi working or Conversations with audio/video calls, or even try matrix/

  1. How I think it would work?

VPS: (apps that need lots of speed)
Nextcloud, encrypted files setting
wireguard node
send app

Home: (stuff that security of data is paramount and lots of data)
transmission app
jellyfin app

  1. What issues have you encountered? what worked for you?

Mostly I read about people using the VPS as a VPN-entry point to their Yunohost at home. That will give a static IP and rDNS, if you don’t have those.

Your goal goes beyond that, by also having part of your ‘Yunohost ecosystem’ running on the VPS.

My ISP went from multiple static IPv4’s + custom rDNS to only one IP. I moved Yunohosts that have limited amounts of data (10-20GB) to a VPS.

The things that need more space, are either

  1. a redirect to the Yunohost running at home (Nextcloud)
  2. using SSHFS to mount a directory at home in the VPS (mostly backups and Peertube)

Neither is perfect. Merging Nextcloud from several servers to a single server gave some headaches, I dropped file shares for example. Users on the ‘VPS’ Yunohosts need to exist on the ‘home’ Yunohost. This is for friends and family’s servers which makes in manageable.

Having directories mounted via SSHFS makes the diagnosis on the VPS Yunohosts complain that permissions are not set correctly; having the mount point occupied sometimes gives difficulty during upgrades.

Nextcloud is reasonably fast. My upload is 50 or 100 Mbit; I think it is running off an SSD (but it is on Proxmox, I’m not quite sure which disk it is on). Backups seem OK (I will have hands-on experience later this week, one of the Yunohosts does not seem to have survived the migration to Yunohost 11). One of the Peertubes got upset during a previous upgrade, and got wiped off that system. I don’t think it is related to using SSHFS; besides that, it works great as well.

Things could be less complex, but all in all I’m reasonably satisfied with the combination.

I’m doing this right now because I moved house and have terrible internet for a few months. Right now I’m using OpenVPN access server to send all traffic to my Yunohost box.

Thanks for sharing your experience. It sounds a little complicated. I think a VPS / home combo would be good for many people though it would be cool if there was a simple solution. I’ll keep thinking about how to do it in the future.

Maybe it would be simpler to not have Yunohost running on the VPS…just run docker containers for some services, and OpenVPN access server (forward ports necessary to LAN).

OpenVPN on VPS forward ports to Yunohost box NGINX running wireguard. Then point NGINX through redirect_ynh to docker services running on VPS with wireguard IP address. Hmm, would that work?

I feel your pain

Hahahaha :smiley:

I think it would work. But if you mean what I understand, (some of?) the traffic would not pass the slow home <–> VPS connection not once, but thrice (entry at the VPS via VPN to Yunohost, and then back to the VPS services, and returning home via VPN to go to the client).

The docker images on the VPS would be just separate services, without SSO or the security benefits of Yunohost’s directory structure (they would be separated nonetheless, so that’s less of an issue).

One benefit is that you can keep running you mailserver on Yunohost at home, via OpenVPN or Wireguard.

Depending on how terrible your temporary internet is, how little you like to pay for a VPS, your demands for bandwidth and requirements to have everything available at all times, some other paths:

  • Creating a backup of your Yunohost at home, and pruning the backup to reduce space. Then restore the lightweight backup on the VPS and put you home-Yunohost in hibernation, only home access, or on an alternate domain until things (internet) change.
  • Still go the SSHFS-route. If only friends and family are using the service, and you can explain to them that until spring the speed will be lower for some things, it could be enough. Synchronizing laptops or phones to Nextcloud can be a lot of data, but often does not need to be very fast. Listening music does not have to take a lot of bandwidth. Matrix, Jitsi and Metronome would be running on the VPS, not needing the slow line back home.

They are variations on a theme of course. I’d be interested to hear how things pan out!

1 Like

And why not going the full VPS path ?

It seems like you’ll end up with a setup merging both VPS and computer at home inconveniences !

  • Some duplicated costs
  • Twice the chance of having something not working somewhere
  • Lower network speed
  • Full setup quite hard to backup or restore

I was thinking about the same setup.
In simple terms, mounting
/home/data of a local debian server in /home/yunohost.multimedia of the remote yunohost vps server using ssh. I’m already mounting yunohost multimedia of my current server on my laptop, it took me a lot of tries and fails to get it to work properly.

1 Like

Yes, that’s an idea. I don’t fully trust another person’s computer. This is why I’ve gone this self-hosting path. Nextcloud has an encrypted data setting but Photoprism doesn’t. Also a VPS would be very expensive to have 300 GB of data on it.

I was just thinking of this now, maybe I should have two servers. VPS for services with little data. My home setup for Jellyfin, Nextcloud, and Photoprism. The key thing for me is not having my personal files (music, videos, pictures) on a VPS.

I understand, but in that case I would have two completely separated Yunohost setups, with one of them handling the emails, the other redirecting emails to the first, and the split between each subdomain being done at DNS zone level. For example, managed by the VPS using Nextcloud, managed by your home server using Photoprism.
No complicated or fancy VPN stuff !

Agreed! If I found a cheaper than $5 USD little, reliable VPS I would probably make the jump.

Then I could maybe get friends/family on board with XMPP/Matrix, SearXNG, and Mastodon.