2020-11-11 11:47:10 +01:00
---
2021-02-07 17:28:00 +01:00
title: Install YunoHost
2020-11-11 11:47:10 +01:00
template: docs
taxonomy:
category: docs
2021-02-07 17:28:00 +01:00
never_cache_twig: true
twig_first: true
process:
markdown: true
twig: true
2021-02-07 20:17:41 +01:00
page-toc:
active: true
depth: 2
2021-02-06 18:22:00 +01:00
routes:
2021-02-08 01:40:06 +01:00
default: '/install'
2021-02-07 17:28:00 +01:00
aliases:
- '/docker'
- '/install_iso'
- '/install_on_vps'
- '/install_manually'
- '/install_on_raspberry'
- '/install_on_arm_board'
- '/install_on_debian'
- '/install_on_virtualbox'
- '/plug_and_boot'
- '/burn_or_copy_iso'
- '/boot_and_graphical_install'
2021-02-08 01:21:28 +01:00
- '/postinstall'
2021-05-08 16:29:56 +02:00
- '/hardware'
2020-11-11 11:47:10 +01:00
---
2021-02-11 03:15:15 +01:00
{% set image_type = 'YunoHost' %}
2022-04-23 23:22:00 +02:00
{% set arm, at_home, regular, rpi2plus, rpi1, rpi0, arm_sup, arm_unsup, vps, vps_debian, vps_ynh, virtualbox, wsl, internetcube, docker = false, false, false, false, false, false, false, false, false, false, false, false, false, false, false %}
2021-02-07 19:37:02 +01:00
{% set hardware = uri.param('hardware') %}
2021-02-07 20:17:41 +01:00
{% if hardware == 'regular' %}
2021-02-07 17:28:00 +01:00
{% set regular = true %}
2021-02-07 20:17:41 +01:00
{% elseif hardware == 'internetcube' %}
2021-02-07 17:28:00 +01:00
{% set arm, arm_sup, internetcube = true, true, true %}
2021-02-11 02:41:57 +01:00
{% set image_type = 'Internet Cube' %}
2021-02-07 20:17:41 +01:00
{% elseif hardware == 'rpi2plus' %}
2021-02-07 17:28:00 +01:00
{% set arm, rpi2plus = true, true %}
2021-02-07 20:17:41 +01:00
{% elseif hardware == 'rpi1' %}
2021-02-07 17:28:00 +01:00
{% set arm, rpi1 = true, true %}
2021-02-07 20:17:41 +01:00
{% elseif hardware == 'rpi0' %}
2021-02-07 17:28:00 +01:00
{% set arm, rpi0 = true, true %}
2021-02-07 20:17:41 +01:00
{% elseif hardware == 'arm_sup' %}
2021-02-07 17:28:00 +01:00
{% set arm, arm_sup = true, true %}
2021-02-07 20:17:41 +01:00
{% elseif hardware == 'arm_unsup' %}
2021-02-07 17:28:00 +01:00
{% set arm, arm_unsup = true, true %}
2021-02-11 02:41:57 +01:00
{% set image_type = 'Armbian' %}
2021-02-07 20:17:41 +01:00
{% elseif hardware == 'vps_debian' %}
2021-02-07 17:28:00 +01:00
{% set vps, vps_debian = true, true %}
2021-02-07 20:17:41 +01:00
{% elseif hardware == 'vps_ynh' %}
2021-02-07 17:28:00 +01:00
{% set vps, vps_ynh = true, true %}
2021-02-07 20:17:41 +01:00
{% elseif hardware == 'virtualbox' %}
2021-02-07 17:28:00 +01:00
{% set at_home, virtualbox = true, true %}
2021-02-07 20:17:41 +01:00
{% elseif hardware == 'docker' %}
2021-02-07 17:28:00 +01:00
{% set docker = true %}
2022-04-23 23:22:00 +02:00
{% elseif hardware == 'wsl' %}
{% set wsl = true %}
2021-02-07 17:28:00 +01:00
{% endif %}
2014-05-14 17:39:04 +02:00
2021-02-07 19:37:02 +01:00
{% if arm or regular %}
{% set at_home = true %}
{% endif %}
2021-02-07 18:56:01 +01:00
Select the hardware on which you want install YunoHost :
[div class="flex-container"]
2021-02-07 19:37:02 +01:00
[div class="flex-child hardware{%if virtualbox %} active{% endif %}"]
2021-02-08 01:59:15 +01:00
[[figure caption="VirtualBox"]![](image://virtualbox.png?height=75)[/figure]](/install/hardware:virtualbox)
2021-02-07 18:56:01 +01:00
[/div]
2021-02-07 19:37:02 +01:00
[div class="flex-child hardware{%if rpi2plus or rpi1 or rpi0 %} active{% endif %}"]
2021-02-08 01:59:15 +01:00
[[figure caption="Raspberry Pi"]![](image://raspberrypi.jpg?height=75)[/figure]](/install/hardware:rpi2plus)
2021-02-07 18:56:01 +01:00
[/div]
2021-02-07 19:37:02 +01:00
[div class="flex-child hardware{%if arm_sup or arm_unsup or internetcube %} active{% endif %}"]
2021-02-08 01:59:15 +01:00
[[figure caption="ARM board"]![](image://olinuxino.jpg?height=75)[/figure]](/install/hardware:arm_sup)
2021-02-07 18:56:01 +01:00
[/div]
2021-02-07 19:37:02 +01:00
[div class="flex-child hardware{%if regular %} active{% endif %}"]
2021-02-08 01:59:15 +01:00
[[figure caption="Regular computer"]![](image://computer.png?height=75)[/figure]](/install/hardware:regular)
2021-02-07 18:56:01 +01:00
[/div]
2022-04-23 23:22:00 +02:00
[div class="flex-child hardware{%if wsl %} active{% endif %}"]
[[figure caption="WSL"]![](image://wsl.png?height=75)[/figure]](/install/hardware:wsl)
[/div]
2021-02-07 19:37:02 +01:00
[div class="flex-child hardware{%if vps_debian or vps_ynh %} active{% endif %}"]
2021-02-08 01:59:15 +01:00
[[figure caption="Remote server"]![](image://vps.png?height=75)[/figure]](/install/hardware:vps_debian)
2021-02-07 18:56:01 +01:00
[/div]
2021-02-07 19:37:02 +01:00
[/div]
2021-02-08 01:15:58 +01:00
[div class="flex-container pt-2"]
2021-02-07 19:37:02 +01:00
{% if rpi2plus or rpi1 or rpi0 %}
[div class="flex-child hardware{%if rpi2plus %} active{% endif %}"]
2021-02-08 02:02:33 +01:00
[[figure caption="Raspberry Pi 2, 3 or 4"]![](image://raspberrypi.jpg?height=50)[/figure]](/install/hardware:rpi2plus)
2021-02-07 19:37:02 +01:00
[/div]
[div class="flex-child hardware{%if rpi1 %} active{% endif %}"]
2021-02-08 02:24:40 +01:00
[[figure caption="Raspberry Pi 1"]![](image://rpi1.jpg?height=50)[/figure]](/install/hardware:rpi1)
2021-02-07 18:56:01 +01:00
[/div]
2021-02-07 19:37:02 +01:00
[div class="flex-child hardware{%if rpi0 %} active{% endif %}"]
2021-02-08 02:24:40 +01:00
[[figure caption="Raspberry Pi zero"]![](image://rpi0.jpg?height=50)[/figure]](/install/hardware:rpi0)
2021-02-07 19:37:02 +01:00
[/div]
{% elseif arm_sup or arm_unsup or internetcube %}
[div class="flex-child hardware{%if internetcube %} active{% endif %}"]
2021-02-08 02:02:33 +01:00
[[figure caption="Internet cube With VPN"]![](image://internetcube.png?height=50)[/figure]](/install/hardware:internetcube)
2021-02-07 19:37:02 +01:00
[/div]
[div class="flex-child hardware{%if arm_sup and not internetcube %} active{% endif %}"]
2021-02-08 02:02:33 +01:00
[[figure caption="Olinuxino lime1& 2 or Orange Pi PC+"]![](image://olinuxino.jpg?height=50)[/figure]](/install/hardware:arm_sup)
2021-02-07 19:37:02 +01:00
[/div]
[div class="flex-child hardware{%if arm_unsup %} active{% endif %}"]
2021-02-08 02:24:40 +01:00
[[figure caption="Others boards"]![](image://odroidhc4.png?height=50)[/figure]](/install/hardware:arm_unsup)
2021-02-07 19:37:02 +01:00
[/div]
{% elseif vps_debian or vps_ynh %}
[div class="flex-child hardware{%if vps_debian %} active{% endif %}"]
2022-08-09 15:38:19 +02:00
[[figure caption="VPS or dedicated server with Debian 11"]![](image://debian-logo.png?height=50)[/figure]](/install/hardware:vps_debian)
2021-02-07 19:37:02 +01:00
[/div]
[div class="flex-child hardware{%if vps_ynh %} active{% endif %}"]
2021-02-08 02:28:45 +01:00
[[figure caption="VPS or dedicated server with YunoHost pre-installed"]![](image://logo.png?height=50)[/figure]](/install/hardware:vps_ynh)
2021-02-07 19:37:02 +01:00
[/div]
{% endif %}
[/div]
2021-02-07 18:56:01 +01:00
2021-02-13 14:04:15 +01:00
{% if hardware != '' %}
2021-02-07 18:56:01 +01:00
2022-04-23 23:22:00 +02:00
{% if wsl %}
!! This setup is mainly meant for local testing by advanced users. Due to limitations on WSL's side (changing IP address, notably), selfhosting from it can be tricky and will not be described here.
{% endif %}
2021-02-07 17:28:00 +01:00
{% if docker %}
!! **YunoHost doesn’ t support Docker officially since issues with versions 2.4+. In question, YunoHost 2.4+ doesn’ t work anymore on Docker because YunoHost requires systemd and Docker has chosen to not support it natively (and there are other problems link to the firewall and services).**
!!
!! **We strongly discourage you to run YunoHost on docker with those images**
2014-05-14 17:39:04 +02:00
2021-02-07 17:28:00 +01:00
## Community images
However, community images exist and are available on Docker Hub:
2021-02-17 11:41:53 +01:00
* [AMD64 (classic) (YunoHost 4.x) ](https://hub.docker.com/r/domainelibre/yunohost/ )
* [I386 (old computers) (YunoHost 4.x) ](https://hub.docker.com/r/domainelibre/yunohost-i386/ )
* [ARM64V8 (Raspberry Pi 4) (YunoHost 4.x) ](https://hub.docker.com/r/cms0/yunohost/ )
* [ARMV7 (Raspberry Pi 2/3 ...) (YunoHost 4.x) ](https://hub.docker.com/r/domainelibre/yunohost-arm/ )
2021-02-07 17:28:00 +01:00
* [ARMV6 (Raspberry Pi 1) (old yunoHost version) ](https://hub.docker.com/r/tuxalex/yunohost-armv6/ )
{% else %}
2021-02-11 01:59:12 +01:00
## [fa=list-alt /] Pre-requisites
2021-02-11 00:03:02 +01:00
2021-02-07 17:28:00 +01:00
{% if regular %}
2021-02-10 19:35:25 +01:00
* A x86-compatible hardware dedicated to YunoHost: laptop, nettop, netbook, desktop with 512MB RAM and 16GB capacity (at least)
2021-02-07 17:28:00 +01:00
{% elseif rpi2plus %}
2021-02-10 19:35:25 +01:00
* A Raspberry Pi 2, 3 or 4
2021-02-07 17:28:00 +01:00
{% elseif rpi1 %}
2021-02-10 19:35:25 +01:00
* A Raspberry Pi 1 with at least 512MB RAM
2021-02-07 17:28:00 +01:00
{% elseif rpi0 %}
2021-02-10 19:35:25 +01:00
* A Raspberry Pi zero
2021-02-11 00:03:02 +01:00
{% elseif internetcube %}
2021-02-13 14:04:15 +01:00
* An Orange Pi PC+ or an Olinuxino Lime 1 or 2
* A VPN with a dedicated public IP and a `.cube` file
2021-02-07 17:28:00 +01:00
{% elseif arm_sup %}
2021-02-13 14:04:15 +01:00
* An Orange Pi PC+ or an Olinuxino Lime 1 or 2
2021-02-07 17:28:00 +01:00
{% elseif arm_unsup %}
2021-02-10 19:35:25 +01:00
* An ARM board with at least 512MB RAM
2021-02-07 17:28:00 +01:00
{% elseif vps_debian %}
2022-08-08 11:14:42 +02:00
* A dedicated or virtual private server with Debian 11 (Bullseye) < small > (with **kernel >= 3.12** )</ small > preinstalled, 512MB RAM and 16GB capacity (at least)
2021-02-07 17:28:00 +01:00
{% elseif vps_ynh %}
2021-02-10 19:35:25 +01:00
* A dedicated or virtual private server with yunohost preinstalled, 512MB RAM and 16GB capacity (at least)
2021-02-07 17:28:00 +01:00
{% elseif virtualbox %}
2021-02-23 18:25:05 +01:00
* An x86 computer with [VirtualBox installed ](https://www.virtualbox.org/wiki/Downloads ) and enough RAM capacity to be able to run a small virtual machine with 1024MB RAM and 8GB capacity (at least)
2021-02-07 17:28:00 +01:00
{% endif %}
{% if arm %}
* A power supply (either an adapter or a MicroUSB cable) for your board;
2021-02-11 00:03:02 +01:00
* A microSD card: 16GB capacity (at least), [class "A1" ](https://en.wikipedia.org/wiki/SD_card#Class ) highly recommended (such as [this SanDisk A1 card ](https://www.amazon.fr/SanDisk-microSDHC-Adaptateur-homologu%C3%A9e-Nouvelle/dp/B073JWXGNT/ ));
2021-02-07 17:28:00 +01:00
{% endif %}
{% if regular %}
2021-02-13 14:04:15 +01:00
* A USB stick with at least 1GB capacity OR a standard blank CD
2021-02-07 17:28:00 +01:00
{% endif %}
2022-04-23 23:22:00 +02:00
{% if wsl %}
* Windows 10 and above
* Administration rights
* Windows Subsystem for Linux, installed from the Optional Features menu of Windows
* *Recommended:* Windows Terminal (Preview) app, installed from the Microsoft Store. Much better than the standard Terminal, as it offers shortcuts to the WSL distros.
{% endif %}
2021-02-07 17:28:00 +01:00
{% if at_home %}
2021-02-10 19:35:25 +01:00
* A [reasonable ISP ](/isp ), preferably with a good and unlimited upstream bandwidth
2021-02-07 17:28:00 +01:00
{% if rpi0 %}
* An usb OTG or a wifi dongle to connect your Raspberry Pi Zero
2021-02-11 00:03:02 +01:00
{% elseif not virtualbox %}
2021-02-07 17:28:00 +01:00
* An ethernet cable (RJ-45) to connect your server to your router.
{% endif %}
2021-02-11 00:03:02 +01:00
* A computer to read this guide, flash the image and access your server.
2021-02-07 17:28:00 +01:00
{% endif %}
{% if not at_home %}
2021-02-11 00:03:02 +01:00
* A computer or a smartphone to read this guide and access your server.
2021-02-07 17:28:00 +01:00
{% endif %}
{% if virtualbox %}
2021-02-13 14:04:15 +01:00
! N.B. : Installing YunoHost in a VirtualBox is usually intended for testing. To run an actual server on the long-term, you usually need a dedicated physical machine (old computer, ARM board...) or a server online.
2021-02-07 17:28:00 +01:00
{% endif %}
2022-04-23 23:22:00 +02:00
{% if wsl %}
## Introduction
2022-08-14 16:58:59 +02:00
WSL is a nice feature of Windows 10, making Linux pseudo-distributions available through command line. Let's say pseudo, because even though they are not really like virtual machines, they rely on virtualization capacities that make their integration with Windows almost seamless.
Docker for Windows can now rely on WSL instead of Hyper-V, for example.
2022-04-23 23:22:00 +02:00
2022-08-14 16:58:59 +02:00
! Bear in mind, this setup itself is *not* a container of any kind. If something breaks, there is no rollback capability.
! You may need to delete the Debian distro altogether and restore it whole.
2022-04-23 23:22:00 +02:00
2022-08-14 16:58:59 +02:00
## Install Debian 11
2022-04-23 23:22:00 +02:00
Let's install YunoHost into its own distro, not altering the default one. In a PowerShell terminal:
```bash
# Let's go in your home directory and prepare the working directories
cd ~
mkdir -p WSL\YunoHost
# Download the Debian appx package and unzip it
curl.exe -L -o debian.zip https://aka.ms/wsl-debian-gnulinux
Expand-Archive .\debian.zip -DestinationPath .\debian
# Import the Debian base into a new distro
wsl --import YunoHost ~\WSL\YunoHost ~\debian\install.tar.gz --version 2
# Cleanup
rmdir .\debian -R
```
You can now access it: run `wsl.exe -d YunoHost`
It is under Debian 9 Stretch, so let's upgrade it:
```bash
# In WSL
2022-08-14 16:58:59 +02:00
sudo sed -i 's/stretch/bullseye/g' /etc/apt/sources.list`
2022-04-23 23:22:00 +02:00
sudo apt update
sudo apt upgrade
sudo apt dist-upgrade
```
## Prevent WSL from tweaking configuration files
Edit `/etc/wsl.conf` and put the following code in it:
```
[network]
generateHosts = false
generateResolvConf = false
```
## Force the use of iptables-legacy
2022-08-14 16:58:59 +02:00
Somehow the YunoHost post-installation does not like `nf_tables` , the new software replacing `iptables` .
We can still explicitely use the good ol' `iptables` though:
2022-04-23 23:22:00 +02:00
```bash
# In WSL
sudo update-alternatives --set iptables /usr/sbin/iptables-legacy
sudo update-alternatives --set ip6tables /usr/sbin/ip6tables-legacy
```
## Install Systemd
2022-08-14 16:58:59 +02:00
Debian on WSL does not have `systemd` , a service configuration software.
This is a key element for YunoHost, and for any decent Debian distro (seriously MS, what the heck). Let's install it:
2022-04-23 23:22:00 +02:00
1. Install dotNET runtime:
```bash
# In WSL
2022-08-14 16:58:59 +02:00
wget https://packages.microsoft.com/config/debian/11/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
2022-04-23 23:22:00 +02:00
sudo dpkg -i packages-microsoft-prod.deb
sudo apt update
sudo apt install -y apt-transport-https
sudo apt update
sudo apt install -y dotnet-sdk-3.1
```
2. Install [Genie ](https://github.com/arkane-systems/genie ):
```bash
# In WSL
# Add their repository
echo "deb [trusted=yes] https://wsl-translinux.arkane-systems.net/apt/ /" > /etc/apt/sources.list.d/wsl-translinux.list
# Install Genie
sudo apt update
sudo apt install -y systemd-genie
```
2022-08-14 16:58:59 +02:00
2022-04-23 23:22:00 +02:00
## Install YunoHost
```bash
# In WSL
# Let's switch to the root user, if you were not already
sudo su
# Initialize the Genie bottle to have systemd running
genie -s
# Your hostname should have been appended with "-wsl"
# Install YunoHost
curl https://install.yunohost.org | bash -s -- -a
```
### Access the command line
Always call `genie -s` while starting your distro.
2021-02-07 20:17:41 +01:00
2022-04-23 23:22:00 +02:00
`wsl -d YunoHost -e genie -s`
## Backup and restore the distro
### Make your first distro backup
2022-08-14 16:58:59 +02:00
As said before, there is no rollback capability. So let's export your fresh distro. In PowerShell:
2022-04-23 23:22:00 +02:00
```
cd ~
wsl --export YunoHost .\WSL\YunoHost.tar.gz
```
2021-02-07 20:17:41 +01:00
2022-04-23 23:22:00 +02:00
### In case of crash, delete and restore the whole distro
```
cd ~
wsl --unregister YunoHost
wsl --import YunoHost .\WSL\YunoHost .\WSL\YunoHost.tar.gz --version 2
```
{% endif %}
2021-02-07 20:17:41 +01:00
2021-02-08 03:53:10 +01:00
{% if vps_ynh %}
## YunoHost VPS providers
Here are some VPS providers supporting YunoHost natively :
2021-02-07 20:17:41 +01:00
2021-02-08 03:53:10 +01:00
[div class="flex-container"]
2021-02-07 20:17:41 +01:00
2021-02-08 03:53:10 +01:00
[div class="flex-child"]
[[figure caption="Alsace Réseau Neutre - FR"]![](image://vps_ynh_arn.png?height=50)[/figure]](https://vps.arn-fai.net)
[/div]
2021-02-07 20:17:41 +01:00
2021-02-08 03:53:10 +01:00
[/div]
{% endif %}
2021-02-07 20:17:41 +01:00
2021-02-07 17:28:00 +01:00
{% if at_home %}
2021-02-11 02:41:57 +01:00
## [fa=download /] Download the {{image_type}} image
2021-02-10 19:35:25 +01:00
2022-09-08 13:52:32 +02:00
! The links to the images are currently broken. While we resolve the issue, you can find them directly on https://build.yunohost.org/
2021-02-13 14:04:15 +01:00
{% if virtualbox or regular %}
2021-02-11 00:03:02 +01:00
!!! If your host OS is 32 bits, be sure to download the 32-bit image.
2021-02-11 03:15:15 +01:00
{% elseif arm_unsup %}
2021-02-13 21:06:52 +01:00
< a href = "https://www.armbian.com/download/" target = "_BLANK" type = "button" class = "btn btn-info col-sm-12" > [fa=external-link] Download the image for your board on Armbian's website< / a >
2022-08-08 11:14:42 +02:00
!!! N.B.: you should download the image Armbian Bullseye.
2021-02-10 19:35:25 +01:00
{% endif %}
2022-01-08 15:12:44 +01:00
!!! If you wish to check the validity of our signed images, you can [download our public key ](https://forge.yunohost.org/yunohost.asc ).
2021-02-10 19:35:25 +01:00
2022-08-08 11:14:42 +02:00
{% if internetcube or arm_sup %}
2022-02-17 21:22:49 +01:00
! Current images are from Debian Buster (YunoHost v4.x) and will require that you perform a manual apt update command in SSH or CLI to continue updating.
! Answer Yes to the warning about switching from stable to oldstable.
2022-08-08 11:14:42 +02:00
{% endif %}
2022-02-17 21:22:49 +01:00
2021-02-07 21:55:01 +01:00
< div class = "hardware-image" >
2021-02-07 17:28:00 +01:00
< div id = "cards-list" >
2021-02-07 22:15:45 +01:00
< / div >
< / div >
2022-09-16 10:45:16 +02:00
< template id = "image-template" >
2021-02-07 22:15:45 +01:00
< div id = "{id}" class = "card panel panel-default" >
2021-02-10 20:13:46 +01:00
< div class = "panel-body text-center pt-2" >
2021-02-07 22:15:45 +01:00
< h3 > {name}< / h3 >
< div class = "card-comment" > {comment}< / div >
2021-02-07 17:28:00 +01:00
< div class = "card-desc text-center" >
2021-02-07 22:15:45 +01:00
< img src = "/user/images/{image}" height = 100 style = "vertical-align:middle" >
2021-02-07 17:28:00 +01:00
< / div >
< / div >
2021-02-07 21:55:01 +01:00
< div class = "annotations flex-container" >
2021-02-07 22:15:45 +01:00
< div class = "flex-child annotation" > < a href = "{file}.sha256sum" > [fa=barcode] Checksum< / a > < / div >
< div class = "flex-child annotation" > < a href = "{file}.sig" > [fa=tag] Signature< / a > < / div >
2021-02-07 17:28:00 +01:00
< / div >
< div class = "btn-group" role = "group" >
2021-02-07 22:15:45 +01:00
< a href = "{file}" target = "_BLANK" type = "button" class = "btn btn-info col-sm-12" > [fa=download] Download < small > {version}< / small > < / a >
2021-02-07 17:28:00 +01:00
< / div >
< / div >
2022-09-16 10:45:16 +02:00
< / template >
2021-02-07 22:15:45 +01:00
< script >
var hardware = "{{ hardware|escape('js') }}";
/*
###############################################################################
Script that loads the infos from JavaScript and creates the corresponding
cards
###############################################################################
*/
$(document).ready(function () {
console.log("in load");
$.getJSON('https://build.yunohost.org/images.json', function (images) {
$.each(images, function(k, infos) {
if (infos.tuto.indexOf(hardware) == -1) return;
// Fill the template
html = $('#image-template').html()
.replace('{id}', infos.id)
.replace('{name}', infos.name)
.replace('{comment}', infos.comment || " ")
2022-09-16 10:45:16 +02:00
.replace('%7Bimage%7D', infos.image)
2021-02-07 22:15:45 +01:00
.replace('{image}', infos.image)
.replace('{version}', infos.version);
2022-09-16 10:45:16 +02:00
if (!infos.file.startsWith("http"))
infos.file="https://build.yunohost.org/"+infos.file;
html = html.replace(/%7Bfile%7D/g, infos.file).replace(/{file}/g, infos.file);
2021-02-07 22:15:45 +01:00
if ((typeof(infos.has_sig_and_sums) !== 'undefined') & & infos.has_sig_and_sums == false)
{
var $html = $(html);
$html.find(".annotations").html(" ");
html = $html[0];
}
$('#cards-list').append(html);
});
});
});
< / script >
2021-02-07 17:28:00 +01:00
2021-02-07 20:17:41 +01:00
2021-02-11 02:41:57 +01:00
2021-02-07 17:28:00 +01:00
{% if not virtualbox %}
{% if arm %}
2021-02-11 02:41:57 +01:00
## ![microSD card with adapter](image://sdcard_with_adapter.png?resize=100,75&class=inline) Flash the {{image_type}} image
2021-02-07 17:28:00 +01:00
{% else %}
2021-02-10 19:35:25 +01:00
## ![USB drive](image://usb_key.png?resize=100,100&class=inline) Flash the YunoHost image
2021-02-07 17:28:00 +01:00
{% endif %}
2021-02-13 14:04:15 +01:00
Now that you downloaded the image of {{image_type}}, you should flash it on {% if arm %}a microSD card{% else %}a USB stick or a CD/DVD.{% endif %}
2021-02-10 19:35:25 +01:00
2021-02-07 17:28:00 +01:00
[ui-tabs position="top-left" active="0" theme="lite"]
[ui-tab title="(Recommended) With Etcher"]
Download < a href = "https://www.balena.io/etcher/" target = "_blank" > Etcher< / a > for your operating system and install it.
2021-03-26 10:01:37 +01:00
Plug your {% if arm %}SD card{% else %}USB stick{% endif %}, select your image and click "Flash"
2021-02-10 19:35:25 +01:00
2021-02-11 00:03:02 +01:00
![Etcher ](image://etcher.gif?resize=700&class=inline )
2021-02-07 17:28:00 +01:00
[/ui-tab]
2021-02-11 00:03:02 +01:00
[ui-tab title="With USBimager"]
2021-02-07 17:28:00 +01:00
2021-02-11 00:03:02 +01:00
Download [USBimager ](https://bztsrc.gitlab.io/usbimager/ ) for your operating system and install it.
2021-02-07 17:28:00 +01:00
2021-02-11 02:41:57 +01:00
Plug your {% if arm %}SD card{% else %}USB stick{% endif %}, select your image and click "Write"
2021-02-07 17:28:00 +01:00
2021-02-11 00:03:02 +01:00
![USBimager ](image://usbimager.png?resize=700&class=inline )
2021-02-07 17:28:00 +01:00
[/ui-tab]
[ui-tab title="With dd"]
If you are on GNU/Linux / macOS and know your way around command line, you may also flash your USB stick or SD card with `dd` . You can identify which device corresponds to your USB stick or SD card with `fdisk -l` or `lsblk` . A typical SD card name is something like `/dev/mmcblk0` . BE CAREFUL and make sure you got the right name.
Then run :
```bash
# Replace /dev/mmcblk0 if the name of your device is different...
dd if=/path/to/yunohost.img of=/dev/mmcblk0
```
[/ui-tab]
{% if regular %}
[ui-tab title="Burning a CD/DVD"]
For older devices, you might want to burn a CD/DVD. The software to use depends on your operating system.
* On Windows, use [ImgBurn ](http://www.imgburn.com/ ) to write the image file on the disc
* On macOS, use [Disk Utility ](http://support.apple.com/kb/ph7025 )
* On GNU/Linux, you have plenty of choices, like [Brasero ](https://wiki.gnome.org/Apps/Brasero ) or [K3b ](http://www.k3b.org/ )
[/ui-tab]
{% endif %}
[/ui-tabs]
{% else %}
2021-02-10 19:35:25 +01:00
2021-02-07 17:28:00 +01:00
## Create a new virtual machine
![](image://virtualbox_1.png?class=inline)
2014-05-14 17:39:04 +02:00
2021-02-13 14:04:15 +01:00
! It's okay if you can only have 32-bit versions, just be sure that you downloaded the 32-bit image previously.
2021-02-11 00:03:02 +01:00
## Tweak network settings
2021-02-07 17:28:00 +01:00
2021-02-10 19:35:25 +01:00
! This step is important to properly expose the virtual machine on the network
2021-02-07 17:28:00 +01:00
Go to **Settings** > **Network** :
* Select `Bridged adapter`
* Select your interface's name:
2021-02-11 00:03:02 +01:00
**wlan0** if you are connected wirelessly, or **eth0** otherwise.
2021-02-07 17:28:00 +01:00
2021-02-10 19:35:25 +01:00
![](image://virtualbox_2.png?class=inline)
2021-02-07 17:28:00 +01:00
{% endif %}
2014-05-14 17:39:04 +02:00
2018-06-14 12:37:34 +02:00
2014-05-14 17:39:04 +02:00
2021-02-07 17:28:00 +01:00
{% if arm %}
2021-02-10 19:35:25 +01:00
## [fa=plug /] Power up the board
* Plug the ethernet cable (one side on your main router, the other on your board).
* For advanced users willing to configure the board to connect to WiFi instead, see for example [here ](https://www.raspberrypi.org/documentation/configuration/wireless/wireless-cli.md ).
2021-02-11 00:03:02 +01:00
* Plug the SD card in your board
* (Optional) You can connect a screen+keyboard directly on your board if you want to troubleshoot the boot process or if you're more comfortable to "see what happens" or want a direct access to the board.
2021-02-07 17:28:00 +01:00
* Power up the board
2021-02-10 19:35:25 +01:00
* Wait a couple minutes while the board autoconfigure itself during the first boot
2021-02-07 17:28:00 +01:00
* Make sure that your computer (desktop/laptop) is connected to the same local network (i.e. same internet box) as your server.
2014-05-14 17:39:04 +02:00
2021-02-07 17:28:00 +01:00
{% elseif virtualbox %}
2021-02-10 19:35:25 +01:00
## [fa=plug /] Boot up the virtual machine
2021-02-07 17:28:00 +01:00
2021-02-10 19:35:25 +01:00
Start the virtual machine after selecting the YunoHost image.
2021-02-07 17:28:00 +01:00
![](image://virtualbox_2.1.png?class=inline)
2021-02-11 00:03:02 +01:00
! If you encounter the error "VT-x is not available", you probably need to enable Virtualization in the BIOS of your computer.
2021-02-07 17:28:00 +01:00
{% else %}
2021-02-10 19:35:25 +01:00
## [fa=plug /] Boot the machine on your USB stick
* Plug the ethernet cable (one side on your main router, the other on your server).
* Boot up your server with the USB stick or a CD-ROM inserted, and select it as **bootable device** by pressing one of the following keys (hardware specific):
`<ESC>` , `<F9>` , `<F10>` , `<F11>` , `<F12>` or `<DEL>` .
* N.B. : if the server was previously installed with a recent version of Windows (8+), you first need to tell Windows, to "actually reboot". This can be done somewhere in "Advanced startup options".
2021-02-07 17:28:00 +01:00
{% endif %}
{% if regular or virtualbox %}
2021-02-11 00:03:02 +01:00
## [fa=rocket /] Launch the graphical install
2021-02-10 19:35:25 +01:00
!! N.B. : The installation will totally erase the data on the server's hard drive!
2021-02-07 17:28:00 +01:00
You should see a screen like this:
[figure class="nomargin" caption="Preview of the ISO menu"]
![](image://virtualbox_3.png?class=inline)
[/figure]
1. Select `Graphical install`
2. Select your language, your location and your keyboard layout
2021-02-10 19:35:25 +01:00
3. The installer will then download and install all required packages.
2021-02-07 17:28:00 +01:00
{% endif %}
2021-02-11 02:06:30 +01:00
{% if rpi1 or rpi0 %}
2021-02-11 02:41:57 +01:00
## [fa=bug /] Connect to the board and hotfix the image
2021-02-13 21:06:52 +01:00
Raspberry Pi 1 and 0 are not totally supported due to [compilation issues for this architecture ](https://github.com/YunoHost/issues/issues/1423 ).
2021-02-11 02:06:30 +01:00
However, it is possible to fix by yourself the image before to run the initial configuration.
To achieve this, you need to connect on your raspberry pi as root user [via SSH ](/ssh ) with the temporary password `yunohost` :
```
ssh root@yunohost.local
```
2021-09-25 17:45:37 +02:00
(or `yunohost-2.local` , and so on if multiple YunoHost servers are on your network)
2021-02-11 02:06:30 +01:00
Then run the following commands to work around the metronome issue:
```
mv /usr/bin/metronome{,.bkp}
mv /usr/bin/metronomectl{,.bkp}
ln -s /usr/bin/true /usr/bin/metronome
ln -s /usr/bin/true /usr/bin/metronomectl
```
And this one to work around the upnpc issue:
```
sed -i 's/import miniupnpc/#import miniupnpc/g' /usr/lib/moulinette/yunohost/firewall.py
```
! This last command need to be run after each yunohost upgrade :/
2021-02-11 02:41:57 +01:00
{% elseif arm_unsup %}
2021-02-13 14:04:15 +01:00
## [fa=terminal /] Connect to the board
2021-02-11 02:41:57 +01:00
Next you need to [find the local IP address of your server ](/finding_the_local_ip ) to connect as root user [via SSH ](/ssh ) with the temporary password `1234` .
```
ssh root@192.168.x.xxx
```
2021-02-11 02:06:30 +01:00
{% endif %}
2021-02-11 02:41:57 +01:00
{% endif %}
2021-02-11 02:06:30 +01:00
2021-02-07 17:28:00 +01:00
2021-02-11 02:41:57 +01:00
{% if vps_debian or arm_unsup %}
2021-02-10 19:35:25 +01:00
## [fa=rocket /] Run the install script
2021-02-07 17:28:00 +01:00
2021-02-11 02:17:16 +01:00
- Open a command line prompt on your server (either directly or [through SSH ](/ssh ))
- Make sure you are root (or type `sudo -i` to become root)
- Run the following command:
2021-02-07 17:28:00 +01:00
```bash
curl https://install.yunohost.org | bash
```
2021-02-10 19:35:25 +01:00
!!! If `curl` is not installed on your system, you might need to install it with `apt install curl` .
2021-02-07 17:28:00 +01:00
!!! Otherwise, if the command does not do anything, you might want to `apt install ca-certificates`
2014-05-14 17:39:04 +02:00
2021-02-10 19:35:25 +01:00
!!! **Note for advanced users concerned with the `curl|bash` approach:** consider reading ["Is curl|bash insecure?" ](https://sandstorm.io/news/2015-09-24-is-curl-bash-insecure-pgp-verified-install ) on Sandstom's blog, and possibly [this discussion on Hacker News ](https://news.ycombinator.com/item?id=12766350&noprocess ).
2021-02-07 17:28:00 +01:00
{% endif %}
2021-02-10 19:35:25 +01:00
2021-02-11 00:03:02 +01:00
## [fa=cog /] Proceed with the initial configuration
2021-02-10 19:35:25 +01:00
!!! If you are in the process of restoring a server using a YunoHost backup, you should skip this step and instead [restore the backup instead of the postinstall step ](/backup#restoring-during-the-postinstall ).
2021-02-07 17:28:00 +01:00
2022-04-23 23:22:00 +02:00
{% if not wsl %}
2021-02-07 17:28:00 +01:00
[ui-tabs position="top-left" active="0" theme="lite"]
[ui-tab title="From the web interface"]
2021-02-10 19:35:25 +01:00
{%if at_home %}
2021-09-25 17:45:37 +02:00
In an internet browser, type ** {% if internetcube %}`https://internetcube.local`{% else %}`https://yunohost.local` (or `yunohost-2.local` , and so on if multiple YunoHost servers are on your network){% endif %}**.
2021-02-10 19:35:25 +01:00
2021-02-13 14:04:15 +01:00
!!! If this doesn't work, you can [look for the the local IP address of your server ](/finding_the_local_ip ). The address typically looks like `192.168.x.y` , and you should therefore type `https://192.168.x.y` in your browser's address bar.
2021-02-10 19:35:25 +01:00
{% else %}
2021-02-13 14:04:15 +01:00
You can perform the initial configuration with the web interface by typing in the adress bar of your web browser **the public IP address of your server** . Typically, your VPS provider should have provided you with the IP of the server.
2021-02-10 19:35:25 +01:00
{% endif %}
2021-02-07 17:28:00 +01:00
2022-04-23 23:22:00 +02:00
{% endif %}
! During the first visit, you will very likely encounter a security warning related to the certificate used by the server. For now, your server uses a self-signed certificate. {% if not wsl %}You will later be able to add a certificate automatically recognized by web browsers as described in the [certificate documentation ](/certificate ). {% endif %} For now, you should add a security exception to accept the current certificate. (Though, PLEASE, do not take the habit of blindly accepting this kind of security alert!)
2021-02-07 17:28:00 +01:00
{% if not internetcube %}
You should then land on this page :
[figure class="nomargin" caption="Preview of the Web initial configuration page"]
![Initial configuration page ](image://postinstall_web.png?resize=100%&class=inline )
[/figure]
{% endif %}
[/ui-tab]
[ui-tab title="From the command line"]
You can also perform the postinstallation with the command `yunohost tools postinstall` directly on the server, or [via SSH ](/ssh ).
[figure class="nomargin" caption="Preview of the command-line post-installation"]
![Initial configuration with CLI ](image://postinstall_cli.png?resize=100%&class=inline )
[/figure]
[/ui-tab]
[/ui-tabs]
{% if not internetcube %}
2021-02-07 18:56:01 +01:00
2021-02-10 19:59:57 +01:00
##### [fa=globe /] Main domain
2021-02-10 19:35:25 +01:00
2021-02-11 00:03:02 +01:00
This will be the domain used by your server's users to access the **authentication portal** . You can later add other domains, and change which one is the main domain if needed.
2021-02-07 17:28:00 +01:00
2022-04-23 23:22:00 +02:00
{% if not wsl %}
2021-02-11 00:03:02 +01:00
* If you're new to self-hosting and do not already have a domain name, we recommend using a ** .nohost.me** / ** .noho.st** / ** .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. Please note that the downside is that you won't have full-control over the DNS configuration.
2021-02-07 17:28:00 +01:00
2021-02-13 21:38:14 +01:00
* If you already own a domain name, you probably want to use it here. You will later need to configure DNS records as explained [here ](/dns_config ).
2021-02-07 17:28:00 +01:00
2021-02-10 19:35:25 +01:00
!!! Yes, you *have to* configure a domain name. If you don't have any domain name and don't want a ** .nohost.me** / ** .noho.st** / ** .ynh.fr** either, you can set up a dummy domain such as `yolo.test` and tweak your `/etc/hosts` file such that this dummy domain points to the appropriate IP, as explained [here ](/dns_local_network )).
2021-02-07 17:28:00 +01:00
2022-04-23 23:22:00 +02:00
{% else %}
You will have to choose a fake domain, since it will not be accessible from outside.
For example, `ynh.wsl` . The tricky part is advertising this domain to your host.
Alter your `C:\Windows\System32\drivers\etc\hosts` file. You should have a line starting by `::1` , update it or add it if needed to get:
```
::1 ynh.wsl localhost
```
If you want to create subdomains, do not forget to add them in the `hosts` file too:
```
::1 ynh.wsl subdomain.ynh.wsl localhost
```
{% endif %}
2021-02-10 19:59:57 +01:00
##### [fa=key /] Administration password
2021-02-07 17:28:00 +01:00
2021-02-11 00:03:02 +01:00
This password will be used to access to your server's administration interface. You will also use it to connect [via **SSH** ](/ssh ) or [**SFTP** ](/filezilla ). In general terms, this is your **system's key** , choose it carefully!
2021-02-07 17:28:00 +01:00
2021-02-10 19:35:25 +01:00
## [fa=user /] Create a first user
2021-02-07 17:28:00 +01:00
2021-02-11 00:03:02 +01:00
Once the postinstall is done, you should be able to actually log in the web admin interface using the administration password.
2021-02-07 17:28:00 +01:00
2021-02-13 21:06:52 +01:00
So far, your server now has an `admin` user - but `admin` is not a "regular" user and *can't* be used to log on [the user portal ](/users ).
2021-02-07 22:50:10 +01:00
2021-02-11 00:03:02 +01:00
Let's therefore add a first "regular" user.
2021-02-07 18:56:01 +01:00
2021-02-10 19:35:25 +01:00
!!! The first user you create is a bit special : it will receive emails sent to `root@yourdomain.tld` and `admin@yourdomain.tld` . These emails may be used to send technical informations or alerts.
2021-02-07 18:56:01 +01:00
2021-02-07 17:28:00 +01:00
[ui-tabs position="top-left" active="0" theme="lite"]
[ui-tab title="From the web interface"]
2021-02-10 19:35:25 +01:00
2022-02-11 18:28:19 +01:00
Go in Users > Click on "+ New User" button
2021-02-10 19:35:25 +01:00
2021-10-15 10:32:34 +02:00
[figure class="nomargin" caption="Preview of the user creation UI"]
![User creation ](image://create-first-user.png?resize=100%&class=inline )
[/figure]
2021-02-07 17:28:00 +01:00
[/ui-tab]
[ui-tab title="From the command line"]
2021-02-07 18:56:01 +01:00
```
yunohost user create johndoe
```
2022-08-20 18:49:11 +02:00
2022-08-27 22:46:27 +02:00
[figure class="nomargin" caption="Preview of the user creation CLI"]
2022-08-20 18:49:11 +02:00
![User creation CLI ](image://create-first-user-cli.png?resize=100%&class=inline )
2022-08-27 22:46:27 +02:00
[/figure]
2021-02-10 19:35:25 +01:00
2021-02-07 17:28:00 +01:00
[/ui-tab]
[/ui-tabs]
{% endif %}
2021-02-10 19:35:25 +01:00
## [fa=stethoscope /] Run the initial diagnosis
2022-04-23 23:22:00 +02:00
{% if wsl %}
! Reminder: YunoHost in WSL will likely not be reachable from outside, and real domains and certificates won't be able to be assigned to it.
{% endif %}
2021-02-11 00:03:02 +01:00
The diagnosis system is meant to provide an easy way to validate that all critical aspects of your server are properly configured - and guide you in how to fix issues. The diagnosis will run twice a day and send an alert if issues are detected.
2021-02-07 20:17:41 +01:00
2021-02-17 12:11:08 +01:00
!!! N.B. : **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 ](/dns_config ) (if not using a `.nohost.me` /`noho.st`/`ynh.fr` domain), add a swapfile if not enough ram {% if at_home %} and/or [port forwarding ](/isp_box_config ){% endif %}.
2021-02-07 22:45:21 +01:00
2021-02-10 19:35:25 +01:00
!!! 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.
2021-02-07 20:17:41 +01:00
2021-02-07 17:28:00 +01:00
[ui-tabs position="top-left" active="0" theme="lite"]
[ui-tab title="(Recommended) From the web interface"]
2022-02-11 18:28:19 +01:00
To run a diagnosis, go on Web Admin in the Diagnosis section. Click Run initial diagnosis and you should get a screen like this :
2021-02-07 22:45:21 +01:00
[figure class="nomargin" caption="Preview of the diagnostic panel"]
![](image://diagnostic.png?resize=100%& class=inline)
[/figure]
2021-02-07 17:28:00 +01:00
[/ui-tab]
[ui-tab title="From the command line"]
2021-02-07 20:17:41 +01:00
```
yunohost diagnosis run
2021-02-10 19:35:25 +01:00
yunohost diagnosis show --issues --human-readable
2021-02-07 20:17:41 +01:00
```
2021-02-07 17:28:00 +01:00
[/ui-tab]
[/ui-tabs]
2014-07-21 16:02:33 +02:00
2021-02-10 19:35:25 +01:00
## [fa=lock /] Get a Let's Encrypt certificate
2021-12-13 16:52:37 +01:00
Once you configured DNS records and port forwarding (if needed), you should be able to install a Let's Encrypt certificate. This will get rid of the spooky security warning from earlier for new visitors.
2021-02-07 19:37:02 +01:00
2022-02-11 18:28:19 +01:00
For more detailed instructions, or to lean more about SSL/TLS certificates, see [the corresponding page here ](/certificate ).
2021-02-07 22:45:21 +01:00
2021-02-07 17:28:00 +01:00
[ui-tabs position="top-left" active="0" theme="lite"]
[ui-tab title="From the web interface"]
2021-02-07 22:45:21 +01:00
2022-02-11 18:28:19 +01:00
Go in Domains > Click on your domain > SSL Certificate
2021-02-07 22:45:21 +01:00
[figure class="nomargin" caption="Preview of the diagnostic panel"]
![](image://certificate-before-LE.png?resize=100%& class=inline)
[/figure]
2021-02-07 17:28:00 +01:00
[/ui-tab]
[ui-tab title="From the command line"]
2021-02-07 19:37:02 +01:00
```
2022-08-20 18:49:11 +02:00
yunohost domain cert install
2021-02-07 19:37:02 +01:00
```
2021-02-07 17:28:00 +01:00
[/ui-tab]
[/ui-tabs]
{% endif %}
2021-02-07 22:50:10 +01:00
2021-02-10 19:35:25 +01:00
## ![](image://tada.png?resize=32&classes=inline) Congratz!
2021-02-07 22:50:10 +01:00
2021-02-13 21:06:52 +01:00
You now have a pretty well configured server. If you're new to YunoHost, we recommend to have a look at [the guided tour ](/overview ). You should also be able to [install your favourite applications ](/apps ). Don't forget to [plan backups ](/backup ) !
2021-02-13 14:04:15 +01:00
{% endif %}