--- title: YunoHost Installieren template: docs taxonomy: category: docs never_cache_twig: true twig_first: true process: markdown: true twig: true page-toc: active: true depth: 2 routes: default: '/install' aliases: - '/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' - '/postinstall' - '/hardware' --- {% set image_type = 'YunoHost' %} {% set arm, at_home, regular, rpi34, rpi012, show_legacy_arm_menu, arm_sup, arm_unsup, vps, vps_debian, vps_ynh, virtualbox, wsl, internetcube = false, false, false, false, false, false, false, false, false, false, false, false, false, false %} {% set hardware = uri.param('hardware') %} {% if hardware == 'regular' %} {% set regular = true %} {% elseif hardware == 'internetcube' %} {% set arm, arm_sup, internetcube = true, true, true %} {% set image_type = 'Internet Cube' %} {% set show_legacy_arm_menu = true %} {% elseif hardware == 'rpi34' %} {% set arm, rpi34 = true, true %} {% elseif hardware == 'rpi012' %} {% set arm, arm_unsup, rpi012 = true, true, true %} {% set image_type = 'Raspberry Pi OS Lite (32-bit, Bullseye)' %} {% elseif hardware == 'arm_sup' %} {% set arm, arm_sup = true, true %} {% set show_legacy_arm_menu = true %} {% elseif hardware == 'arm' %} {% set arm, arm_unsup = true, true %} {% set image_type = 'Armbian' %} {% elseif hardware == 'arm_unsup' %} {% set arm, arm_unsup = true, true %} {% set show_legacy_arm_menu = true %} {% set image_type = 'Armbian' %} {% elseif hardware == 'vps_debian' %} {% set vps, vps_debian = true, true %} {% elseif hardware == 'vps_ynh' %} {% set vps, vps_ynh = true, true %} {% elseif hardware == 'virtualbox' %} {% set at_home, virtualbox = true, true %} {% elseif hardware == 'wsl' %} {% set wsl = true %} {% endif %} {% if arm or regular %} {% set at_home = true %} {% endif %} Wähle die Hardware, auf der du YunoHost installieren willst : [div class="flex-container"] [div class="flex-child hardware{%if virtualbox %} active{% endif %}"] [[figure caption="VirtualBox"]![](image://virtualbox.png?height=75)[/figure]](/install/hardware:virtualbox) [/div] [div class="flex-child hardware{%if rpi012 or rpi34 %} active{% endif %}"] [[figure caption="Raspberry Pi"]![](image://raspberrypi.png?height=75)[/figure]](/install/hardware:rpi34) [/div] [div class="flex-child hardware{%if arm_sup or (arm_unsup and not rpi012) or internetcube %} active{% endif %}"] [[figure caption="ARM Board"]![](image://olinuxino.png?height=75)[/figure]](/install/hardware:arm) [/div] [div class="flex-child hardware{%if regular %} active{% endif %}"] [[figure caption="Normaler Computer"]![](image://computer.png?height=75)[/figure]](/install/hardware:regular) [/div] [div class="flex-child hardware{%if wsl %} active{% endif %}"] [[figure caption="WSL"]![](image://wsl.png?height=75)[/figure]](/install/hardware:wsl) [/div] [div class="flex-child hardware{%if vps_debian or vps_ynh %} active{% endif %}"] [[figure caption="Remote Server"]![](image://vps.png?height=75)[/figure]](/install/hardware:vps_debian) [/div] [/div] [div class="flex-container pt-2"] {% if rpi012 or rpi34 %} [div class="flex-child hardware{%if rpi34 %} active{% endif %}"] [[figure caption="Raspberry Pi 3 oder 4"]![](image://raspberrypi.png?height=50)[/figure]](/install/hardware:rpi34) [/div] [div class="flex-child hardware{%if rpi012 %} active{% endif %}"] [[figure caption="Raspberry Pi 0, 1 oder 2"]![](image://rpi1.png?height=50)[/figure]](/install/hardware:rpi012) [/div] {% elseif show_legacy_arm_menu %} [div class="flex-child hardware{%if internetcube %} active{% endif %}"] [[figure caption="Internet cube mit VPN"]![](image://internetcube.png?height=50)[/figure]](/install/hardware:internetcube) [/div] [div class="flex-child hardware{%if arm_sup and not internetcube %} active{% endif %}"] [[figure caption="Olinuxino lime1&2 oder Orange Pi PC+"]![](image://olinuxino.png?height=50)[/figure]](/install/hardware:arm_sup) [/div] [div class="flex-child hardware{%if arm_unsup %} active{% endif %}"] [[figure caption="Andere Boards"]![](image://odroidhc4.png?height=50)[/figure]](/install/hardware:arm_unsup) [/div] {% elseif vps_debian or vps_ynh %} [div class="flex-child hardware{%if vps_debian %} active{% endif %}"] [[figure caption="VPS oder dedizierter Server mit Debian 11"]![](image://debian-logo.png?height=50)[/figure]](/install/hardware:vps_debian) [/div] [div class="flex-child hardware{%if vps_ynh %} active{% endif %}"] [[figure caption="VPS oder dedizierter Server mit YunoHost vorinstalliert"]![](image://logo.png?height=50)[/figure]](/install/hardware:vps_ynh) [/div] {% endif %} [/div] {% if hardware != '' %} {% if wsl %} !! Dieses Setup ist vorwiegend für lokales Testing durch fortgeschrittene Benutzer gedacht. Aufgrund Limitierungen auf WSL Seite (insbesondere veränderliche IP Adresse), selfhosting kann damit knifflig sein und wird hier nicht weiter beschrieben. {% endif %} ## [fa=list-alt /] Pre-requisites {% if regular %} * Eine x86-kompatible für YunoHost bestimmte (dedizierte) Hardware: Laptop, Nettop, Netbook, Desktop mit 512MB RAM und 16GB Speicherkapazität (Minimum) {% elseif rpi34 %} * Ein Raspberry Pi 3 oder 4 {% elseif rpi012 %} * Ein Raspberry Pi 0, 1 oder 2 mit mindestens 512MB RAM {% elseif internetcube %} * Ein Orange Pi PC+ oder ein Olinuxino Lime 1 oder 2 * Ein VPN mit einer festen öffentlichen IP Adresse und einer `.cube` Datei {% elseif arm_sup %} * Ein Orange Pi PC+ oder ein Olinuxino Lime 1 oder 2 {% elseif arm_unsup %} * Ein ARM Board mit mindestens 512MB RAM {% elseif vps_debian %} * Ein dedizierter oder Virtual Private Server mit Debian 11 (Bullseye) (mit **kernel >= 3.12**) vorinstalliert, 512MB RAM und 16GB Speicherkapazität (Minimum) {% elseif vps_ynh %} * Ein dedizierter oder Virtual Private Server mit YunoHost vorinstalliert, 512MB RAM und 16GB Speicherkapazität (Minimum) {% elseif virtualbox %} * Ein x86 Computer mit [VirtualBox installiert](https://www.virtualbox.org/wiki/Downloads) und ausreichend Arbeitsspeicherkapazität (RAM), um eine kleine virtuelle Maschine mit 1024MB RAM und 8GB Speicherkapazität (Minimum) betreiben zu können {% endif %} {% if arm %} * Eine Spannungsversorung (entweder ein Netzteil oder ein MicroUSB Kabel) für dein Board; * Eine microSD Karte: 16GB Speicherkapazität (Minimum), [class "A1"](https://en.wikipedia.org/wiki/SD_card#Class) nachdrücklich empfohlen (so wie [diese SanDisk A1 Karte](https://www.amazon.fr/SanDisk-microSDHC-Adaptateur-homologu%C3%A9e-Nouvelle/dp/B073JWXGNT/)); {% endif %} {% if regular %} * Ein USB Stick mit mindestens 1GB Speicherkapazität ODER einem Standard CD-Rohling {% endif %} {% if wsl %} * Windows 10 und neuer * Administrator Rechte * Windows Subsystem for Linux, aus dem Optional Features Menü von Windows installiert * *Empfohlen:* Windows Command Prompt App, aus dem Microsoft Store installiert. Viel besser als der Standard Terminal, weil sie Shortcuts für WSL distros bietet. {% endif %} {% if at_home %} * Ein [vernünftiger ISP](/isp), vorzugsweise mit einer guten und unbegrenzten Upstream Bandbreite {% if not virtualbox %} * Ein Ethernet Kabel (RJ-45), um deinen Server mit deinem Router zu verbinden. {% if rpi012 %} (Oder, für Rasperry Pi Zero : und USB OTG oder ein Wifi Dongle) {% endif %} {% endif %} * Ein Computer, um diese Anleitung zu lesen, das Image zu flashen und auf deinen Server zuzugreifen. {% else %} * Ein Computer oder ein Smartphone, um diese Anleitung zu lesen und auf deinen Server zuzugreifen. {% endif %} {% if virtualbox %} ! Anmerkung : YunoHost in einer VirtualBox zu installieren ist normalerweise nur zu Test- oder Entwicklungszwecken gedacht . Es ist nicht dafür geeignet einen wirklichen Server langfristig zu betreiben, weil die Machine auf der es installiert ist wahrscheinlich nicht 24/7 laufen wird und weil VirtualBox eine zusätzliche Komplexitätsschicht beim Freigeben der Maschine zum Internet mitbringt. {% endif %} {% if wsl %} ## Vorstellung WSL ist ein cooles Windows 10 Feature, das Linux pseudo-Distributionen durch die Kommandozeile verfügbar macht. Lass es uns pseudo nennen, weil auch obwohl sie nicht wirklich wie virtuelle Maschinen sind, sind sie auf Virtualisierungskapazitäten angewiesen, die deren Integration mit Windows fast nahtlos machen. So kann z.B. Docker für Windows jetzt auf WSL bauen, anstatt auf Hyper-V. ! Beachte, dass dieses Setup selbst *kein* Container jeglicher Art ist. Falls etwas bricht, gibt es keine Rollback Möglichkeit. ! Vielleicht musst du die Debian Distro vollkommen löschen und ganz wiederherstellen. ## Installation in Debian 11 Lass uns YunoHost in einem PowerShell Terminal in seine eigene Distro installieren und nicht die default Distro verändern: ```bash # Geh in dein home Verzeichnis und bereite die Arbeitsverzeichnisse vor cd ~ mkdir -p WSL\YunoHost # Lade das Debian appx Paket herunter und entpacke es (unzip) curl.exe -L -o debian.zip https://aka.ms/wsl-debian-gnulinux Expand-Archive .\debian.zip -DestinationPath .\debian # Importiere Debian als Grundlage in eine neue Distro wsl --import YunoHost ~\WSL\YunoHost ~\debian\install.tar.gz --version 2 # Aufräumen rmdir .\debian -R ``` Nun kannst du darauf zugreifen: Führe `wsl.exe -d YunoHost` aus. Da es Debian 9 Stretch ist, lass uns ein Upgrade auf Debian 11 Bullseye machen: ```bash # In WSL sudo sed -i 's/stretch/bullseye/g' /etc/apt/sources.list` sudo apt update sudo apt upgrade sudo apt dist-upgrade ``` ## Verhindern, dass WSL an Konfigurationsdateien herumfeilt Bearbeite `/etc/wsl.conf` und füge den folgenden Code darin ein: ``` [network] generateHosts = false generateResolvConf = false ``` ## Erzwinge die Verwendung von iptables-legacy Irgendwie mag die YunoHost Post-Installation `nf_tables` nicht, die neue Software ersetzt `iptables`. Wir können trotzdem immer noch explizit die guten alten `iptables` benutzen: ```bash # In WSL sudo update-alternatives --set iptables /usr/sbin/iptables-legacy sudo update-alternatives --set ip6tables /usr/sbin/ip6tables-legacy ``` ## Systemd installieren Unter WSL fehlt Debian `systemd`, eine Service-Konfigurations-Software. Diese ist ein Schlüsselelement für YunoHost, und für jede anständige Debian Distro (also ernsthaft Microsoft, was zum Henker). Lass es uns installieren: 1. Installation der dotNET Runtime: ```bash # In WSL wget https://packages.microsoft.com/config/debian/11/packages-microsoft-prod.deb -O packages-microsoft-prod.deb 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. Installation von [Genie](https://github.com/arkane-systems/genie): ```bash # In WSL # Das repository hinzufügen echo "deb [trusted=yes] https://wsl-translinux.arkane-systems.net/apt/ /" > /etc/apt/sources.list.d/wsl-translinux.list # Genie installieren sudo apt update sudo apt install -y systemd-genie ``` ## YunoHost Installation ```bash # In WSL # zum root user wechseln, wenn you das nicht schon bist sudo su # Die Genie Flasche initialisiern, um systemd am Laufen zu haben genie -s # Dein hostname sollte mit "-wsl" enden # Installiere YunoHost curl https://install.yunohost.org | bash -s -- -a ``` ### Öffne die Kommandozeile Rufe `genie -s` immer während des Startes deiner Distro auf. `wsl -d YunoHost -e genie -s` ## Backup und Wiederherstellung der Distro ### Mache dein erstes Distro Backup Wie zuvor gesagt, gibt es keine Rollback Möglichkeit. Lass uns deshal deine frische Distro exportieren. In PowerShell: ``` cd ~ wsl --export YunoHost .\WSL\YunoHost.tar.gz ``` ### Im Falle eines Crash, lösche und stelle die gesamte Distro wieder her ``` cd ~ wsl --unregister YunoHost wsl --import YunoHost .\WSL\YunoHost .\WSL\YunoHost.tar.gz --version 2 ``` {% endif %} {% if vps_ynh %} ## YunoHost VPS Provider Hier sind ein paar VPS Provider, die YunoHost nativ unterstützen : [div class="flex-container"] [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] [div class="flex-child"] [[figure caption="FAImaison - FR"]![](image://vps_ynh_faimaison.svg?height=50)[/figure]](https://www.faimaison.net/services/vm.html) [/div] [div class="flex-child"] [[figure caption="Association ECOWAN - FR"]![](image://vps_ynh_ecowan.png?height=50)[/figure]](https://www.ecowan.fr/vps-linux) [/div] [/div] {% endif %} {% if at_home %} ## [fa=download /] Lade das {{image_type}} Image herunter {% if rpi012 %} ! Leider wird der Support für Rasperry Pi 0, 1 und 2 so langsam eingestellt : Das Bauen neuer Images ist komplex und RPi 0, 1 und 2 sind ARM-32bit Systeme, die über die Zeit mehr und mehr veralten (deprecated) werden. Da unsere vorinstallierten Images ziemlich alt sind, empfehlen wir stattdessen das [offizielle Rasperry Pi OS Lite (**32-bit**, **Bullseye**)](https://downloads.raspberrypi.org/raspios_lite_armhf/images/?C=M;O=D) zu downloaden und YunoHost [unter Verwendung ähnlicher Instruktionen wie für andere ARM Boards](/install/hardware:arm) oben drauf zu installieren. {% endif %} {% if virtualbox or regular %} !!! Achte darauf, dass du das 32-bit Image herunterlädst, wenn dein Host ein 32 Bit System ist. {% elseif arm_unsup and not rpi012 %} [fa=external-link] Lade das Image für dein Board auf der Armbian Website herunter. !!! Anmerkung: Du solltest das Image Armbian Bullseye downloaden. {% endif %} !!! Wenn du die Validität deiner signierten Images prüfen will, kannst du [unseren public key downloaden](https://forge.yunohost.org/yunohost.asc). {% if internetcube or arm_sup %} ! Aktuelle Images stammen von Debian Buster (YunoHost v4.x) und erfordern, dass du einen manuellen apt update Befehl per SSH oder CLI durchführst, um weiter zu aktualisieren. ! Antworte mit Ja auf die Warnung über den Wechsel von stable zu oldstable. {% endif %}
{% if not virtualbox %} {% if arm %} ## ![microSD Karte mit Adapter](image://sdcard_with_adapter.png?resize=100,75&class=inline) Flash das {{image_type}} Image {% else %} ## ![USB Stick](image://usb_key.png?resize=100,100&class=inline) Flash das YunoHost Image {% endif %} Jetzt wo du das Image von {{image_type}} heruntergeladen hast, solltest du es auf {% if arm %}einer microSD Karte{% else %}einem USB stick oder einer CD/DVD flashen.{% endif %} [ui-tabs position="top-left" active="0" theme="lite"] [ui-tab title="(Empfohlen) Mit Etcher"] Lade Etcher für dein Betriebssystem herunter und installiere es. Steck {% if arm %}die SD Karte{% else %}den USB Stick{% endif %} an, wähle dein Image und klicke "Flash". ![Etcher](image://etcher.gif?resize=700&class=inline) [/ui-tab] [ui-tab title="Mit USBimager"] Lade [USBimager](https://bztsrc.gitlab.io/usbimager/) für dein Betriebssystem herunter und installiere es. Steck {% if arm %}die SD Karte{% else %}den USB Stick{% endif %} an, wähle dein Image und klicke "Write". ![USBimager](image://usbimager.png?resize=700&class=inline) [/ui-tab] [ui-tab title="Mit dd Befehl"] Wenn du mit GNU/Linux / macOS arbeitest und dich mit der Kommandozeile auskennst, kannst du deinen USB Stick oder deine SD Karte auch mit `dd` flashen. Du kannst mit `fdisk -l` oder `lsblk` feststellen welches Device deinem USB stick oder deiner SD Karte entspricht. Ein typischer SD Karten Name ist sowas wie `/dev/mmcblk0`. SEI VORSICHTIG und stelle sicher, dass du den richtigen Namen hast. Führe dann Folgendes aus : ```bash # Ersetze /dev/mmcblk0 durch das richtige Device, wenn der Name deines Device anders ist... dd if=/path/to/yunohost.img of=/dev/mmcblk0 ``` [/ui-tab] {% if regular %} [ui-tab title="Eine CD/DVD brennen"] Für ältere Geräte könntest du eine CD/DVD brennen wollen. Die zu verwendende Software hängt von deinem Betriebssystem ab. * Auf Windows, benutze [ImgBurn](http://www.imgburn.com/), um die Image Datei auf die Disc zu schreiben. * Auf macOS, benutze [Disk Utility](http://support.apple.com/kb/ph7025) * Auf GNU/Linux hat man eine große Auswahl, wie [Brasero](https://wiki.gnome.org/Apps/Brasero) oder [K3b](http://www.k3b.org/) [/ui-tab] {% endif %} [/ui-tabs] {% else %} ## Erzeuge eine neue virtuelle Maschine ![](image://virtualbox_1.png?class=inline) ! Es ist in Ordnung, wenn du nur 32-bit Versionen haben kannst. Sei einfach sicher, dass du zuvor das 32-bit Image heruntergeladen hast. ## Netzwerk Einstellungen justieren ! Dieser Schritt ist wichtig, um die virtuelle Maschine ordnungsgemäß im Netzwerk zugänglich zu machen. Gehe zu **Settings** > **Network**: * Wähle `Bridged adapter` * Wähle den Namen deines Interface: **wlan0**, wenn du kabellos verbunden bist, oder andernfalls **eth0**. ![](image://virtualbox_2.png?class=inline) {% endif %} {% if arm %} ## [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). * 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. * Power up the board * Wait a couple minutes while the board autoconfigure itself during the first boot * Make sure that your computer (desktop/laptop) is connected to the same local network (i.e. same internet box) as your server. {% elseif virtualbox %} ## [fa=plug /] Boot up the virtual machine Start the virtual machine after selecting the YunoHost image. ![](image://virtualbox_2.1.png?class=inline) ! If you encounter the error "VT-x is not available", you probably need to enable Virtualization in the BIOS of your computer. {% else %} ## [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): ``, ``, ``, ``, `` or ``. * 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". {% endif %} {% if regular or virtualbox %} ## [fa=rocket /] Launch the graphical install You should see a screen like this: [figure class="nomargin" caption="Preview of the ISO menu"] ![](image://virtualbox_3.png?class=inline) [/figure] [ui-tabs position="top-left" active="0" theme="lite"] [ui-tab title="Installation classique sur un disque entier"] !! N.B.: Once you have validated the keyboard layout, the installation will be launched and will completely erase the data on your hard disk! 1. Select `Graphical install` 2. Select your language, your location, your keyboard layout, and eventually your timezone. 3. The installer will then download and install all required packages. [/ui-tab] [ui-tab title="Installation in expert mode"] The YunoHost project simplified the classic installation as much as possible in order to avoid as many people as possible being lost with questions that are too technical or related to specific cases. With the expert mode installation, you have more possibilities, especially concerning the exact partitioning of your storage media. You can also decide to use the classic mode and [add your disks afterwards](/external_storage). ### Summary of the steps in expert mode: 1. Select `Expert graphical install`. 2. Select your language, location, keyboard layout and possibly your timezone. 3. Partition your disks. This is where you can set up a RAID or encrypt all or part of the server. 4. Specify a possible HTTP proxy to use for the installation of the packages 5. Specify on which volumes grub should be installed ### Regarding partitioning In general, we recommend against partitioning `/var`, `/opt`, `/usr`, `/bin`, `/etc`, `/lib`, `/tmp` and `/root` on separate partitions. This will prevent you from having to worry about full partitions that could crash your machine, cause app installations to fail, or even corrupt your databases. For performance reasons, it is recommended to mount your fastest storage (SSD) on the root `/`. If you have one or more hard drives to store data, you can choose to mount it on one of these folders depending on your usage. | Path | Contents | |--------|---| | `/home` | User folders accessible via SFTP | | `/home/yunohost.backup/archives` | YunoHost backups to be placed ideally elsewhere than on the disks that manage the data | | `/home/yunohost.app` | Heavy data from YunoHost applications (nextcloud, matrix...) | | `/home/yunohost.multimedia` | Heavy data shared between several applications | | `/var/mail` | User mail If you want flexibility and don't want to (re)size partitions, you can also choose to mount on `/mnt/hdd` and follow this [tutorial to mount all these folders with `mount --bind`](/external_storage). ### About encryption Be aware that if you encrypt all or part of your disks, you will have to type the passphrase every time you restart your server, which can be a problem if you are not on site. There are however solutions (quite difficult to implement) that allow you to type the passphrase via SSH or via a web page (search for "dropbear encrypted disk"). ### About RAID Keep in mind that: * the disks in your RAIDs must be of different brands, wear and tear or batches (especially if they are SSDs) * a RAID 1 (even without a spare) is more reliable than a RAID 5 from a probability point of view * hardware raids are dependent on the raid card, if the card fails you will need a replacement to read and rebuild the array [/ui-tab] [/ui-tabs] {% endif %} {% if rpi012 %} ## [fa=bug /] Connect to the board and hotfix the image Raspberry Pi 1 and 0 are not totally supported due to [compilation issues for this architecture](https://github.com/YunoHost/issues/issues/1423). 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 ``` (or `yunohost-2.local`, and so on if multiple YunoHost servers are on your network) 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 :/ {% elseif arm_unsup %} ## [fa=terminal /] Connect to the board 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 ``` {% endif %} {% endif %} {% if vps_debian or arm_unsup %} ## [fa=rocket /] Run the install script - 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: ```bash curl https://install.yunohost.org | bash ``` !!! If `curl` is not installed on your system, you might need to install it with `apt install curl`. !!! Otherwise, if the command does not do anything, you might want to `apt install ca-certificates` !!! **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). {% endif %} ## [fa=cog /] Proceed with the initial configuration !!! 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). [ui-tabs position="top-left" active="0" theme="lite"] [ui-tab title="From the web interface"] {%if at_home %} 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 %}**. !!! 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. {% else %} You can perform the initial configuration with the web interface by typing in the address 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. {% 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!) {% 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 %} ##### [fa=globe /] Main domain 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. {% if not wsl %} * 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. * 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). !!! 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 **local** `/etc/hosts` file such that this dummy domain [points to the appropriate IP, as explained here](/dns_local_network). {% 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 %} ##### [fa=key /] First user [Since YunoHost 11.1](https://forum.yunohost.org/t/yunohost-11-1-release-sortie-de-yunohost-11-1/23378), the first user is now created at this stage. You should pick a username and a reasonably complex password. (We cannot stress enough that the password should be **robust**!) This user will be added to the Admins group, and will therefore be able to access the user portal, the web admin interface, and connect [via **SSH**](/ssh) or [**SFTP**](/filezilla). Admins will also receive emails sent to `root@yourdomain.tld` and `admin@yourdomain.tld` : these emails may be used to send technical informations or alerts. You can later add additional users, which you can also add to the Admins group. This user replaces the old `admin` user, which some old documentation page may still refer to. In which case : just replace `admin` with your username. ## [fa=stethoscope /] Run the initial diagnosis Once the postinstall is done, you should be able to actually log in the web admin interface using the credentials of the first user you just created. {% 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 %} {% if virtualbox %} ! Reminder: YunoHost in VirtualBox will likely not be reachable from outside without further network configuration in Virtualbox's settings. The diagnosis will probably complain about this. {% endif %} 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. !!! 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 %}. !!! 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. [ui-tabs position="top-left" active="0" theme="lite"] [ui-tab title="(Recommended) From the web interface"] To run a diagnosis, go on Web Admin in the Diagnosis section. Click Run initial diagnosis and you should get a screen like this : [figure class="nomargin" caption="Preview of the diagnostic panel"] ![](image://diagnostic.png?resize=100%&class=inline) [/figure] [/ui-tab] [ui-tab title="From the command line"] ``` yunohost diagnosis run yunohost diagnosis show --issues --human-readable ``` [/ui-tab] [/ui-tabs] ## [fa=lock /] Get a Let's Encrypt certificate 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. For more detailed instructions, or to lean more about SSL/TLS certificates, see [the corresponding page here](/certificate). [ui-tabs position="top-left" active="0" theme="lite"] [ui-tab title="From the web interface"] Go in Domains > Click on your domain > SSL Certificate [figure class="nomargin" caption="Preview of the diagnostic panel"] ![](image://certificate-before-LE.png?resize=100%&class=inline) [/figure] [/ui-tab] [ui-tab title="From the command line"] ``` yunohost domain cert install ``` [/ui-tab] [/ui-tabs] ## ![](image://tada.png?resize=32&classes=inline) Congratz! 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) ! {% endif %} {% endif %}