How to self-host with Yunohost

What’s Yunohost?

Pronounced “why-u-no-host?” Yunohost is an amazing foss project for managing a server and self-hosting your web presence. It’s designed to be user friendly, and Yunohost’s interface lets you manage your server administration with a GUI which is great for noobs who are scared of ssh and the command line.

It’s extremely easy to install, and you can be up and running in minutes with a cheap VPS. A cheap VPS can be had for as little as $3 or $5 per month, and you can host your own email, and a couple apps. You can spend more and get a beefier VPS and install more apps. The VPS I am describing in this article, is $10/month from Vultr, and it is hosting my email & xmpp, Castopod, Peertube, Peertube search index, Pleroma, Searx, and WordPress (this website).

You don’t even need a domain name. Yunohost will provide you with a free one, and you’ll choose if you want to use it or not during install, although it may be long, awkward, and unwieldy. So, if you want a cool or funny domain, your best bet may be to buy one.

You can pick up a cheap domain for a little as a dollar, if you don’t care about getting one that ends in .com.

Namecheap sells domains for a buck, and there are even services like Freenom, which will give you a domain for free (but you don’t own it until you buy it, so be aware that there’s some restrictions on what you can do with your free domain if you go this route). I actually started this website with a free domain from Freenom and then purchased it outright from them later on.

How to install Yunohost

There are a few different ways to install Yunohost depending on your hardware. Since mine is on a VPS, that is what I’ll cover here. If your situation is different, here are the docs: Yunohost Installation.

Yunohost prerequisites:

  • A dedicated or virtual private server with Debian 10 (Buster) (with kernel >= 3.12) preinstalled, 512MB RAM and 16GB capacity (at least)
  • A computer or a smartphone to read this guide and access your server.

Doing the deed: Running the installation script

  • Open a command line prompt on your server (either directly or through SSH)
  • Make sure you are root (or type sudo -i to become root)
  • Run the following command:
curl https://install.yunohost.org | bash

Once the installation finishes, navigate to your public IP address, and complete the installation. You’ll receive a warning from your browser, because you haven’t set up an SSL certificate yet, disregard the warning and proceed to your IP address.

You’ll be prompted to set a main domain. Here is where you choose to use a domain provided by Yunohost, or one you’ve purchased. You’ll also be prompted to create an admin user. You should also click the Diagnosis tab and run the diagnosis. Yunohost’s documentation gives the following warning:

don’t run away ! The first time you run the diagnosis, it is quite expected to see a bunch of yellow/red alerts because you typically need to configure DNS records (if not using a .nohost.me/noho.st/ynh.fr domain), add a swapfile if not enough ram .

If an alert is not relevant (for example because you don’t intend on using a specific feature), it is perfectly fine to flag the issue as ‘ignored’ by going in the webadmin > Diagnosis, and clicking the ignore button for this specifc issue.”

Once you finished finalizing the install, you’ll need to create DNS records for your domain, so you can get your SSL encryption certificates. This is probably the most difficult/confusing part, but it necessary for your apps, xmpp, and certificates to function properly.

When you click on your domains tab:

You should see the domain you set. Click on it and you should see a screen like this:

If you click the DNS configuration, it will give you the necessary information to set up your DNS records with your hosting, domain registrar, or service like cloudflare. The DNS configuration looks like this:

In the Yunohost documentation they decipher this mishmash like this:

Once you’ve added all the necessary DNS records, you can click on the domains tab and then your domain again, from the Yunohost admin GUI, and click SSL Certificate. Then click Install Let’s Encrypt Certificate. Shortly after, you should get a message that the certificate was successfully installed. Your certificates should auto-renew every 90 days.

Now, you should be able to navigate to your domain with no complaints from your browser, and you should see a little padlock indicating SSL encryption near your domain name in your browser. If this is the case, you’re ready to start installing some apps.

If not, I recommend reading through the docs to figure out what you misconfigured. Remember to clear your browser cache to be sure.

Installing apps on Yunohost

If you click the applications tab, you should see a screen similar to this, but without any installed applications.

To install your first app, click the green button, and you’ll be taken to a menu page:

Choose an app from the catalog, by selecting a category then one of the apps, or searching by name in the search bar:

Some of the less popular apps are not maintained, and may have bugs, security issues, or old versions. These should be labeled as not maintained. I think the star means that the app is actively maintained and high quality, but I could be mistaken.

When choosing an app to install on your Yunohost server, always make sure to read the readme BEFORE installing

The readme tab always contains any useful information or application specific requirements like a dedicated subdomain. So, for example, my Peertube instance required me to create a CNAME record for the subdomain peertube.runfox.tk. Every app is different, so just be sure to read the readme first because it will let you know before you make a mistake.

When you’re ready to install the app, and you have read through the readme file, click the green install button and the app will be installed.

Then you should be able to navigate to the domain, or subdomain to see your app live, and use it. Login with the login info you created when you installed the app.

Yunohost is dope

There are literally hundreds of apps to install, it is super simple, and the Yunohost community is friendly and helpful.

You can take a look at the full list of Yunohost applications, here: Yunohost Apps Catalog.

You can look at Yunohost’s documentation, here: Yunohost Documentation

You can donate to the Yunohost project, here: Donate to Yunohost

You can get a hold of someone to talk to about Yunohost here:

  • Matrix (#yunohost:libera.chat using Element)
  • IRC (#yunohost on libera.chat, using kiwiirc)
  • XMPP (support@conference.yunohost.org)

Alternatively, you can post on the forum if that’s more your style:

Yunohost Forum

And, last, but definitely not least, if you’d like to contribute to the project, you can here: Contribute to Yunohost.

I’d like to thank the volunteers working on the project, because I love my Yunohost server. It lets me be a first class citizen of the web, and avoid the censorship and deplatforming that’s endemic online right now. I think self-hosting is the most important concept for freedom other than crypto decentralizing money, removing it from the state, and making it open source.

Everyone should self host, and now with Yunohost, they can. There are other options to do the same thing, and self-host, although none of them offer the user-friendly simplicity of Yunohost. Just like everyone will have a Bitcoin node in the future, I think everyone will have a server that they self-host their own cloud and fediverse with.

In my next article, we’ll add a BTCPay server to our arsenal for self-sovereignty. Until next time, and God Bless!

If you’d like to support my work

You can donate here with Bitcoin, Lightning Network, or Monero
https://runfox.tk/wp/product/donate-bitcoin-onchain-lightning-network-or-monero/

Or you can donate to my crowdfund with Bitcoin, Lightning Network, or Monero:
https://cipherassetanalysis.com/apps/4VKDJ6Yjsg24F2otzXmFv1rBzZPJ/crowdfund

You can also become a monthly Librepatron, with Bitcoin, Lightning Network, or Monero:
https://libre.cipherassetanalysis.com/

“And I will pray the Father, and he shall give you another Comforter, that he may abide with you for ever;”
John 14:16 (KJV)

Leave a Reply

Your email address will not be published. Required fields are marked *