Yunohost Workshop

This is work in progress, I will update this post this week on a regular basis

Hey all,

Coming Thursday I want to give an online workshop on installing YNH on a VPS.
The workshop will be 90-120 minutes long and there will be max 30 participants.

At the end every participant should have:

  • a working VPS
  • with YNH installed
  • at least one working app
  • and two users
  • a general idea on how to continue and where to look for help (on this forum)

Bonus points would be to

  • install a Let’s Encrypt Cert.
  • cover how to update the server
  • go over the backup methods

There is a Dutch hoster so kind to sponsor me with 30 VPSs that participants of the workshop can continue using for free for 3 months after the workshop ends.

I thought I will write out my plan on how to give this workshop here and hope that people will like the idea and maybe have ideas for improvements

So without further ado, here is the plan. Please react with improvements or stuff I might have missed!

Workshop - Working at Home in the Public Stack.

An online workshop 30 April 20:00 - 21:30.

  • Estimated participants: 30
  • Knowledge level: Novice
  • Channel: Zoom

Each participant will have access to a VPS with:

  • 1 CPU Core
  • 1.024 MB RAM
  • 50 GB SSD
  • 1 TB Pooled Traffic.

Prerequisites
Stuff every participant should have arranged before they enter the workshop

  • A desktop or laptop with MacOS or Linux (Sorry, no Windows support…)
  • A charger, or a full enough battery for two hours of surfing and live video conferencing.
  • The link to the Jitsi room. Please enter on time and check your A/V settings.
  • A link to a private zerobin with their username and password for their server (and maybe some other details…

1. Introduction

In the introduction I want to talk about how the internet is build up of a network of networks and that there are different typologies on how a network can be structured: Centralized, Decentralized and Distributed.

In an ideal, resilient, privacy-friendly world everyone is able to talk with everyone without an intermediary; the distributed model. But due to many constraints; resources, network effects, security, investment models and the structure of the capital market, the internet has converged to the centralized model in which a few super-nodes take care of the majority of interpersonal en intermachine communication.

To install a YNH server is a step in the right direction from totally centralized towards decentralized (but not yet distributed). What we will do is to reclaim a node in the network to serve the participants and their relatives with their own private decentralized space for communication of any sort.

Which software are we going to use and why?

This gives a good oppertunity to explain a little about the different layers in the stack and the public stack.

  • We start with TransIP: the network layer. Sadly no Public Stack here. But what is a hoster? What do they look like? I can show some datacentre and marinecable images to get some idea.
  • Debian 9; The OS layer. Robust, floss OS that is known for its security and stability. Has been part of the public stack for decades.
  • Yunohost: a, primarily French, floss project that has been going for many years and has as a primal objective to make hosting yourself easy. They have come a long way and are getting better and better. They are under active development and, very important, they have an active supportive community online.
  • Nextcloud: a, primarily German, floss project that was forked from Owncloud and has seen rapid improvement in the last years; they make running your private cloud easy.
  • and a whole slew of dependencies; php. mysql, nginx etc. etc.

Now we get to work!

2. SSH into your VPS and Install YNH.

To communicate with the VPS we use SSH.

Note:

  • I installed all VPS’s before hand. I noted the IP address, login, password and root password in an excel file.
  • I created a Zero/PrivateBin installation with the help of YNH and created a unique paste for every participant containing their login details.
  • I send this link to every participant using the private message feature of Jitsi.
  1. Open the terminal program on your computer.
  2. Type ssh waag@[your ip adress] and hit enter.

The authenticity of host '[ip adress] can’t be established.
ECDSA key fingerprint is SHA256:7ROrZxxxeIxxxxxxxxxxxxxxxxxxxxxxxxxxxxx30.
Are you sure you want to continue connecting (yes/no)?

  1. confirm adding the server to your host file by typing yes and hitting enter.
  2. become root: su -
  3. type root password
  4. install yunohost

curl https://install.yunohost.org | bash

  1. Confirm you want to overwrite system files.
  2. Confirm you want to change SSH behaviour

3. Post installation.

Perform the post-installation with the web interface by entering in your browser: the public IP address of the server.

  • Explain the security warning people are likely to encounter related to the certificate used by the server.
  • add a security exception to accept the current certificate.

We will then walk through the steps together for the post-installation:

  • Main domain
    People do not have a domain; only an IP, so we will use the YunoHost’s DynDNS service and choose a sub-domain of .nohost.me , .noho.st or .ynh.fr (e.g. homersimpson.nohost.me ). Provided that it’s not already taken, the domain will be configured automatically and you won’t need any further configuration step.

Note: Add information for people who have their own domain and refer to the DNS page page for more information.

  • Administration password
    This password will be used to access to your server’s administration interface. You would also use it to connect via SSH or SFTP . In general terms, this is your system’s key , choose it carefully.

4. We are in and can create our first user!

Let’s setup the first user who is going to be using this machine. Probably you yourself.

Note: add information on the difference between users and admins

You can create accounts for multiple users: let’s try one more; a friend, your partner/kid or housemate.

5. And now the fun stuff; what do you want to do with a server for yourself?

Think about the apps that you’ve been using with your friends and family to communicate? Or do you want a private serach engine? Do you chat a lot over WhatsApp? Do you share files? Do you have a household with a shared calendar?

What is the functionality that you’d like to replace and run on your own private server?

  • We’re going to look at Nextcloud as I believe this is an extremly powerfull piece of software that can enable you to do a lot of stuff:
  • Share files between people and/or machines
  • Backup files (auto upload from your smartphone!)
  • Calendar/Contact sync
  • And it support apps in itself.

Note: how is the LDAP support between YNH and NC…?

Walk through the installation steps:

Note: explain that there might be small differences in these steps as every app is different; show where people can find the read.me and the project page on github.

  • choose an app
  • Choose a label
  • choose a domain
  • choose a path (!)

explain difference between subdomains and subdirectories

End with testing: and pointing out that NExtcloud has a mobile and desktop app. And that many apps can be installed, but that there are limitation due to RAM and CPU constraints.

7 Likes

Hi there,

Fantastic idea! That is a great way to spread the good news about YNH!

As for your questions + a few suggestions:

  • NC and YNH LDAP: AFAIK it’s transparent, NC is patched/configured to use the YNH LDAP
  • maybe talk about choosing a good provider for the VPS (you expect people to stay on the Dutch hoster I guess).
  • if you talk about backups (and indeed you should), do you plan on mentioning restore steps as well?
1 Like

Hey @Vinz thnx for your input and reply!

  • I will test the NC and YNH integration today
  • What do you think should be discussed when talking about a ‘good provider’? There is often very little to find on providers other then what they say about themselves on their own website. But for sure spinning up your server on one of the big cloud platforms doesn’t help contributing to a more diverse internet…
  • I wasn’t planning to talk about backups… I find them complicated and opaque myself. I miss a straightforward way to download a backup file through the webinterface of YNH and a way to upload one to restore a backup

Also, which apps would you recommend to show to new users?

Hi @dosch,

Glad this small bit of info helped! As for your questions, here are some bits:

What do you think should be discussed when talking about a ‘good provider’? There is often very little to find on providers other then what they say about themselves on their own website. But for sure spinning up your server on one of the big cloud platforms doesn’t help contributing to a more diverse internet…

Yes, you are correct. This will depend on your audience and I would advise you start the workshop by asking why they came. To me, the biggest driver for people to use YNH is to regain control of their data. Thus the following would be important as a start to me for a good provider:

  • datacenter presence in a country which has correct “data rights”. This usually means a European presence (i.e outside of reach of the US Cloud Act). Then the particular country would have to be considered (sorry I don’t have particular info here, I am interested if you do)
  • whether the provider is a good citizen of the Internet (i.e. collaborating w/ Free/Libre projects or the W3C, etc)
  • the overall experience for a newbie/someone starting to host, etc

I wasn’t planning to talk about backups… I find them complicated and opaque myself. I miss a straightforward way to download a backup file through the webinterface of YNH and a way to upload one to restore a backup

You had mentioned “Backup files (auto upload from your smartphone!)” in your list above which is why I thought you had planned on talking about them. I still think you should, I think this is critical when hosting a server (I am not an admin though, more on the dev side). What happens if all goes down? Or at least explain how they can replicate their files across devices (as you said, via the smartphone app).

The YNH backups via the UI are easy to do, it’s the restore part that I am still not very well versed in. You are supposed to be able to install YNH and point at a backup archive to restore a full system, as detailed here (check the “Restoring backups” part) but I have not tested it. The YNH devs put great care into writing this feature so as to make it easy to backup/restore.

Also, which apps would you recommend to show to new users?

Excellent question. Again, depends on your audience:

  • I would focus on Nextcloud indeed (get back your data, share w/ others, excellent integration w/ mobile platforms, modern look and feel). There is so much functionality there, I think it’s a key piece of data sovereignity.
  • I’d show you can easily install other apps, showing the highest quality ones. Dokuwiki is a great one to collaborate on doc for instance
1 Like

in case anyone considers doing this as well…

This is an intense 2 hours, but worth it.

I had 42 participants and about 30 of them managed to install YNH.

2 Likes

Hey @dosch,

Thanks for the feedback. Very glad it went well! Did you eventually got more information on why those people were interested in YNH?

Hey @Vinz, I do not think that anyone had heard of YNH before the workshop, so I don’t think it was their topic of interest.

But all present said they were interested in learning how to get more control of their data. And they were happy to learn something that was dooable.

It was a big struggle for them to get it installed (some of them didn’t know what a terminal was), but after that everyone was amazed how easy it is to install apps and create users.

I think if I do it again, I will split it into a few smaller workshops; three times one hour with some homework assignments in between is maybe better to do, then two hours at once.

1 Like

Thanks @dosch for the feedback. Interesting to see quite some peopleanaged to get it installed that way, it’s great!

Yes I agree multiple workshops is a good idea, especially w/ homework in-between.

Good luck with the next training!

Wow, nice and intense work here @dosch :heart_eyes: I ran such a workshop with 5-8 people in the same room, and it was not easy… So having it through Zoom was a step higher ! Congrats :clap:

As mentionned by others, I think :floppy_disk: backup is not to be avoided, however hard or uneasy it can be. Especially with less-skilled people, they will rely on this VPS as for their digital life, and having no backup can be tragic… Hope you found a way to get the topic on the table !

I’m not sure about mutiple-session workshops : where would you divide ? It’s hard to do something with a half-installed yunohost >< Don’t people rather tend to forgot between sessions ?

Anyway, thanks for sharing this experience with us, it may encourage others to get to it :smiley:

PS : out of curiosity, how did you “recruit” your audience ? Is this people you already knew from other common interests ?

1 Like

Indeed. but probably having one session with “getting it installed / working” and then “discovering how to use all the features” are two things that are somewhat independant…

Also the complexity of getting it installed imho can vary a lot depending if you prepared a few things (like pre-buying VPS online or preparing hardware in advance … though that has other implications if the goal is really that people go back home with their very own stuff)

the tutorial is really helpful atleast for me

1 Like

I know YNH has a manual backup function. There are YNH apps that can do a backup. OS’s like debian offer backup functionality and often a hoster has a back-up service.

What would you say are the essential/best steps to do a good back up from which a user can recover a server?

There are so many layers of depth you can apply; for instance, I skipped over the OS installation completely this time. As I discovered; some people do not know what a terminal is. A homework assignment could be to walk through a simple terminal tutorial to get an idea of what curl, cd, mv etc. do.

Also, I think that ideally you would do a five day workshop, and every morning between 10 and 11 you take one hour to go over some steps.

I did this workshop for Waag, a Dutch research institute on the social aspects of technology. They advertised it in their newsletter and on their website.

Yeah, this is a difficult point: I hope that I can explain people this on an abstract enough level that they realize what the limits and possibilities are. But, as said, I already skipped over the installation of debian as that would’ve been a workshop in itself for some people.

Also, getting a RaspPi up and running is almost impossible for many people. So yeah, to be able to really show the magic of YNH I had to cut some corners and those corners could be addressed when making alonger workshop, possibly of separated chapters.

2 Likes

Thanks for your answser, it’s really nice to have those community insights :smiley_cat:

Well, my personnal routine amounts to 3 points :

  • If you’re on a VPS, find a way to have snapshots (and maybe automate them ?), it’s the easiest way to recover.
  • On Ynh, use the backup function regularly, at least for “core” (that doesn’t require a lot of diskspace). I use a script in /etc/cron.weekly
  • Then, get thoses backups out on another disk : again a simple script, with rsync for example to a NAS, or manually using FileZilla.

Have fun, and godspeed to your Ynh workshops!

1 Like

almost three years later I got the question to give the workshop again. So I am bumping this for my own convience, but also for other to see if I might have missed things the first time.

Also, this time the workshop will be live and not online!

So I had a little fun giving a Yunohost workshop in real life.

Here I leave my setup for the workshop and an overview.
Also, some things to consider for next time:

  • take time to explain what would be needed for self-hosting at home (port forwarding, good up-link, YNH compatible HW)
  • Maybe explain more linux
  • Take more time to explain the different layers of software (OS, Yunohost, Apps)

5 Likes