From a531e78ef6e8ac3b26a003a9fb7a5424b7ae6c12 Mon Sep 17 00:00:00 2001 From: Olivier Le Thanh Duong Date: Fri, 3 May 2024 07:58:11 +0200 Subject: [PATCH] Installation documentation was moved to aleph doc Point to it in the documentation and removed duplicated information here --- README.md | 4 +- doc/INSTALL-Debian-11.md | 169 +---------------------------------- doc/INSTALL-Debian-12.md | 170 +---------------------------------- doc/INSTALL-Ubuntu-20.04.md | 11 +-- doc/INSTALL-Ubuntu-22.04.md | 171 +----------------------------------- doc/INSTALL.md | 4 +- 6 files changed, 6 insertions(+), 523 deletions(-) diff --git a/README.md b/README.md index 9b3733300..783f02a09 100644 --- a/README.md +++ b/README.md @@ -17,9 +17,7 @@ Writing programs in Python using ASGI compatible frameworks ( Install Aleph-VM to run an Aleph.im Compute Resource Node easily from official pre-built packages. -- [On Debian 11](./doc/INSTALL-Debian-11.md) -- [On Debian 12](./doc/INSTALL-Debian-12.md) -- [On Ubuntu 22.04](./doc/INSTALL-Ubuntu-22.04.md) +See the official user doc https://docs.aleph.im/nodes/compute/ ## 2. Install Aleph-VM from source diff --git a/doc/INSTALL-Debian-11.md b/doc/INSTALL-Debian-11.md index 577fe4ac0..242296c04 100644 --- a/doc/INSTALL-Debian-11.md +++ b/doc/INSTALL-Debian-11.md @@ -1,168 +1 @@ -# Installing Aleph-VM on a server / Debian 11 Bullseye - -## 0. Introduction - -For production using official Debian packages. - -## 1. Requirements - -- A [supported Linux server](../src/aleph/vm/orchestrator/README.md#1-supported-platforms) -- A public domain name from a registrar and top level domain you trust. - -In order to run an official Aleph.im Compute Resource Node (CRN), you will also need the following resources: - -- CPU (2 options): - - Min. 8 cores / 16 threads, 3.0 ghz+ CPU (gaming CPU for fast boot-up of microVMs) - - Min. 12 core / 24 threads, 2.4ghz+ CPU (datacenter CPU for multiple concurrent loads) -- RAM: 64GB -- STORAGE: 1TB (NVMe SSD preferred, datacenter fast HDD possible under conditions, you’ll want a big and fast cache) -- BANDWIDTH: Minimum of 500 MB/s - -You will need a public domain name with access to add TXT and wildcard records. - -> 💡 This documentation will use the invalid `vm.example.org` domain name. Replace it when needed. - -## 2. Installation - -Run the following commands as `root`: - -First install the [VM-Connector](../vm_connector/README.md) using Docker: -```shell -apt update -apt upgrade -apt install -y docker.io apparmor-profiles -docker run -d -p 127.0.0.1:4021:4021/tcp --restart=always --name vm-connector alephim/vm-connector:alpha -``` - -Then install the [VM-Supervisor](../src/aleph/vm/orchestrator/README.md) using the official Debian package. -The procedure is similar for updates. -```shell -wget -P /opt https://github.com/aleph-im/aleph-vm/releases/download/0.3.1/aleph-vm.debian-11.deb -apt install /opt/aleph-vm.debian-11.deb -``` - -Reboot if required (new kernel, ...). - -### Configuration - -Update the configuration in `/etc/aleph-vm/supervisor.env` using your favourite editor. - -#### Hostname - -You will want to insert your domain name in the form of: -``` -ALEPH_VM_DOMAIN_NAME=vm.example.org -``` - -#### Network configuration - -On some systems, the default network interface is not `eth0` and you will want to configure the default interface -by adding: -``` -ALEPH_VM_NETWORK_INTERFACE=enp0s1 -``` -(don't forget to replace `enp0s1` with the name of your default network interface). - -Debian 11 by default uses `/etc/resolv.conf` for DNS resolution. The VM Supervisor uses this by default. -If your system uses [systemd-resolved](https://manpages.debian.org/bullseye/systemd/systemd-resolved.8.en.html) -instead, uncomment and add the following setting: -``` -#ALEPH_VM_DNS_RESOLUTION=resolvctl -``` - -> 💡 You can instead specify the DNS resolvers used by the VMs using `ALEPH_VM_DNS_NAMESERVERS=["1.2.3.4", "5.6.7.8"]`. - -#### Volumes and partitions - -Two directories are used to store data from the network: -- `/var/lib/aleph/vm` contains all the execution and persistent data. -- `/var/cache/aleph/vm` contains data downloaded from the network. - -These two directories must be stored on the same partition. -That partition must meet the minimum requirements specified for a CRN. - -> 💡 This is required due to the software using hard links to optimize performance and disk usage. - -#### Applying changes - -Finally, restart the service: -```shell -systemctl restart aleph-vm-supervisor -``` - -## 3. Reverse Proxy - -We document how to use Caddy as a reverse proxy since it manages and renews HTTPS certificates automatically. - -Any other reverse-proxy (Nginx, HAProxy, Apache2, ...) should do the job as well, just make sure to renew the -HTTPS/TLS certificates on time. - -First, create a domain name that points to the server on IPv4 (A) and IPv6 (AAAA). - -This is a simple configuration. For more options, check [CONFIGURE_CADDY.md](/CONFIGURE_CADDY.md). - -Again, run these commands as `root`: -```shell - apt install -y debian-keyring debian-archive-keyring apt-transport-https -curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | gpg --dearmor -o /usr/share/keyrings/caddy-stable-archive-keyring.gpg -curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | tee /etc/apt/sources.list.d/caddy-stable.list -apt update -apt install caddy -``` - -Then, after replacing the domain `vm.example.org` with your own, use configure Caddy: -```shell -cat >/etc/caddy/Caddyfile < ![image](https://user-images.githubusercontent.com/404665/150202090-91a02536-4e04-4af2-967f-fe105d116e1f.png) - -If you face an issue, check the logs of the different services for errors: - -VM-Supervisor: -```shell -journalctl -f -u aleph-vm-supervisor.service -``` - -Caddy: -```shell -journalctl -f -u caddy.service -``` - -VM-Connector: -```shell -docker logs -f vm-connector -``` - -### Common errors - -#### "Network interface eth0 does not exist" - -Did you update the configuration file `/etc/aleph-vm/supervisor.env` with `ALEPH_VM_NETWORK_INTERFACE` equal to -the default network interface of your server ? - -#### "Aleph Connector unavailable" - -Investigate the installation of the VM-Connector using Docker in step 2. +[[https://docs.aleph.im/nodes/compute/installation/debian-11/]] \ No newline at end of file diff --git a/doc/INSTALL-Debian-12.md b/doc/INSTALL-Debian-12.md index e3826b327..bc2b74cb7 100644 --- a/doc/INSTALL-Debian-12.md +++ b/doc/INSTALL-Debian-12.md @@ -1,169 +1 @@ -# Installing Aleph-VM on a server / Debian 12 Bookworm - -## 0. Introduction - -For production using official Debian packages. - -## 1. Requirements - -- A [supported Linux server](../src/aleph/vm/orchestrator/README.md#1-supported-platforms) -- A public domain name from a registrar and top level domain you trust. - -In order to run an official Aleph.im Compute Resource Node (CRN), you will also need the following resources: - -- CPU (2 options): - - Min. 8 cores / 16 threads, 3.0 ghz+ CPU (gaming CPU for fast boot-up of microVMs) - - Min. 12 core / 24 threads, 2.4ghz+ CPU (datacenter CPU for multiple concurrent loads) -- RAM: 64GB -- STORAGE: 1TB (NVMe SSD preferred, datacenter fast HDD possible under conditions, you’ll want a big and fast cache) -- BANDWIDTH: Minimum of 500 MB/s - -You will need a public domain name with access to add TXT and wildcard records. - -> 💡 This documentation will use the invalid `vm.example.org` domain name. Replace it when needed. - -## 2. Installation - -Run the following commands as `root`: - -First install the [VM-Connector](../vm_connector/README.md) using Docker: -```shell -apt update -apt upgrade -apt install -y docker.io apparmor-profiles -docker run -d -p 127.0.0.1:4021:4021/tcp --restart=always --name vm-connector alephim/vm-connector:alpha -``` - -Then install the [VM-Supervisor](../src/aleph/vm/orchestrator/README.md) using the official Debian package. -The procedure is similar for updates. -```shell -wget -P /opt https://github.com/aleph-im/aleph-vm/releases/download/0.3.1/aleph-vm.debian-12.deb -apt install /opt/aleph-vm.debian-12.deb -``` - -Reboot if required (new kernel, ...). - -### Configuration - -Update the configuration in `/etc/aleph-vm/supervisor.env` using your favourite editor. - -#### Hostname - -You will want to insert your domain name in the form of: -``` -ALEPH_VM_DOMAIN_NAME=vm.example.org -``` - -#### Network configuration - -The network configuration is detected automatically. - -The default network interface is detected automatically from the IP routes. -You can configure the default interface manually instead by adding: -``` -ALEPH_VM_NETWORK_INTERFACE=enp0s1 -``` -(don't forget to replace `enp0s1` with the name of your default network interface). - -You can configure the DNS resolver manually by using one of the following options: -``` -ALEPH_VM_DNS_RESOLUTION=resolvectl -ALEPH_VM_DNS_RESOLUTION=resolv.conf -``` - -> 💡 You can instead specify the DNS resolvers used by the VMs using `ALEPH_VM_DNS_NAMESERVERS=["1.2.3.4", "5.6.7.8"]`. - -#### Volumes and partitions - -Two directories are used to store data from the network: -- `/var/lib/aleph/vm` contains all the execution and persistent data. -- `/var/cache/aleph/vm` contains data downloaded from the network. - -These two directories must be stored on the same partition. -That partition must meet the minimum requirements specified for a CRN. - -> 💡 This is required due to the software using hard links to optimize performance and disk usage. - -#### Applying changes - -Finally, restart the service: -```shell -systemctl restart aleph-vm-supervisor -``` - -## 3. Reverse Proxy - -We document how to use Caddy as a reverse proxy since it manages and renews HTTPS certificates automatically. - -Any other reverse-proxy (Nginx, HAProxy, Apache2, ...) should do the job as well, just make sure to renew the -HTTPS/TLS certificates on time. - -First, create a domain name that points to the server on IPv4 (A) and IPv6 (AAAA). - -This is a simple configuration. For more options, check [CONFIGURE_CADDY.md](/CONFIGURE_CADDY.md). - -Again, run these commands as `root`: -```shell - apt install -y debian-keyring debian-archive-keyring apt-transport-https -curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | gpg --dearmor -o /usr/share/keyrings/caddy-stable-archive-keyring.gpg -curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | tee /etc/apt/sources.list.d/caddy-stable.list -apt update -apt install caddy -``` - -Then, after replacing the domain `vm.example.org` with your own, use configure Caddy: -```shell -cat >/etc/caddy/Caddyfile < ![image](https://user-images.githubusercontent.com/404665/150202090-91a02536-4e04-4af2-967f-fe105d116e1f.png) - -If you face an issue, check the logs of the different services for errors: - -VM-Supervisor: -```shell -journalctl -f -u aleph-vm-supervisor.service -``` - -Caddy: -```shell -journalctl -f -u caddy.service -``` - -VM-Connector: -```shell -docker logs -f vm-connector -``` - -### Common errors - -#### "Network interface eth0 does not exist" - -Did you update the configuration file `/etc/aleph-vm/supervisor.env` with `ALEPH_VM_NETWORK_INTERFACE` equal to -the default network interface of your server ? - -#### "Aleph Connector unavailable" - -Investigate the installation of the VM-Connector using Docker in step 2. +[[https://docs.aleph.im/nodes/compute/installation/debian-12/]] \ No newline at end of file diff --git a/doc/INSTALL-Ubuntu-20.04.md b/doc/INSTALL-Ubuntu-20.04.md index 0cd067b36..6705c5bb7 100644 --- a/doc/INSTALL-Ubuntu-20.04.md +++ b/doc/INSTALL-Ubuntu-20.04.md @@ -1,10 +1 @@ -# Installing Aleph-VM on a server / Ubuntu 20.04 Focal Fossa (Deprecated) - -Support for Ubuntu 20.04 was due to compatibility issues with -the NFTables firewall introduced in version -[0.2.6](https://github.com/aleph-im/aleph-vm/releases/tag/0.2.6). - -We recommend upgrading to the newest Ubuntu LTS version -and then use the -[following instructions on Ubuntu 22.04](./INSTALL-Ubuntu-22.04.md) -). +Moved to [[https://docs.aleph.im/nodes/compute/installation/ubuntu-20.04/]] \ No newline at end of file diff --git a/doc/INSTALL-Ubuntu-22.04.md b/doc/INSTALL-Ubuntu-22.04.md index b4fdfeb0d..010b81536 100644 --- a/doc/INSTALL-Ubuntu-22.04.md +++ b/doc/INSTALL-Ubuntu-22.04.md @@ -1,170 +1 @@ -# Installing Aleph-VM on a server / Ubuntu 22.04 Jammy Jellyfish - -## 0. Introduction - -For production using official Debian packages. - -## 1. Requirements - -- A [supported Linux server](../src/aleph/vm/orchestrator/README.md#1-supported-platforms) -- A public domain name from a registrar and top level domain you trust. - -In order to run an official Aleph.im Compute Resource Node (CRN), you will also need the following resources: - -- CPU (2 options): - - Min. 8 cores / 16 threads, 3.0 ghz+ CPU (gaming CPU for fast boot-up of microVMs) - - Min. 12 core / 24 threads, 2.4ghz+ CPU (datacenter CPU for multiple concurrent loads) -- RAM: 64GB -- STORAGE: 1TB (NVMe SSD preferred, datacenter fast HDD possible under conditions, you’ll want a big and fast cache) -- BANDWIDTH: Minimum of 500 MB/s - -You will need a public domain name with access to add TXT and wildcard records. - -> 💡 This documentation will use the invalid `vm.example.org` domain name. Replace it when needed. - -## 2. Installation - -Run the following commands: - -First install the [VM-Connector](../vm_connector/README.md) using Docker: -```shell -sudo apt update -sudo apt upgrade -sudo apt install -y docker.io -docker run -d -p 127.0.0.1:4021:4021/tcp --restart=always --name vm-connector alephim/vm-connector:alpha -``` - -Then install the [VM-Supervisor](../src/aleph/vm/orchestrator/README.md) using the official Debian package. -The procedure is similar for updates. -```shell -sudo wget -P /opt https://github.com/aleph-im/aleph-vm/releases/download/0.3.1/aleph-vm.ubuntu-22.04.deb -sudo apt install /opt/aleph-vm.ubuntu-22.04.deb -``` - -Reboot if required (new kernel, ...). - -### Configuration - -#### Hostname - -Update the configuration in `/etc/aleph-vm/supervisor.env` using your favourite editor. - -You will want to insert your domain name in the form of: -``` -ALEPH_VM_DOMAIN_NAME=vm.example.org -``` - -#### Network configuration - -The network configuration is detected automatically. - -The default network interface is detected automatically from the IP routes. -You can configure the default interface manually instead by adding: -``` -ALEPH_VM_NETWORK_INTERFACE=enp0s1 -``` -(don't forget to replace `enp0s1` with the name of your default network interface). - -You can configure the DNS resolver manually by using one of the following options: -``` -ALEPH_VM_DNS_RESOLUTION=resolvectl -ALEPH_VM_DNS_RESOLUTION=resolv.conf -``` - -> 💡 You can instead specify the DNS resolvers used by the VMs using `ALEPH_VM_DNS_NAMESERVERS=["1.2.3.4", "5.6.7.8"]`. - - -#### Volumes and partitions - -Two directories are used to store data from the network: -- `/var/lib/aleph/vm` contains all the execution and persistent data. -- `/var/cache/aleph/vm` contains data downloaded from the network. - -These two directories must be stored on the same partition. -That partition must meet the minimum requirements specified for a CRN. - -> 💡 This is required due to the software using hard links to optimize performance and disk usage. - -#### Applying changes - -Finally, restart the service: -```shell -sudo systemctl restart aleph-vm-supervisor -``` - -## 3. Reverse Proxy - -We document how to use Caddy as a reverse proxy since it manages and renews HTTPS certificates automatically. - -Any other reverse-proxy (Nginx, HAProxy, Apache2, ...) should do the job as well, just make sure to renew the -HTTPS/TLS certificates on time. - -First, create a domain name that points to the server on IPv4 (A) and IPv6 (AAAA). - -This is a simple configuration. For more options, check [CONFIGURE_CADDY.md](/CONFIGURE_CADDY.md). - -Again, run these commands as `root`: -```shell -sudo apt install -y debian-keyring debian-archive-keyring apt-transport-https -curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | sudo gpg --dearmor -o /usr/share/keyrings/caddy-stable-archive-keyring.gpg -curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | sudo tee /etc/apt/sources.list.d/caddy-stable.list -sudo apt update -sudo apt install caddy -``` - -Then, after replacing the domain `vm.example.org` with your own, use configure Caddy: -```shell -sudo cat >/etc/caddy/Caddyfile < ![image](https://user-images.githubusercontent.com/404665/150202090-91a02536-4e04-4af2-967f-fe105d116e1f.png) - -If you face an issue, check the logs of the different services for errors: - -VM-Supervisor: -```shell -sudo journalctl -f -u aleph-vm-supervisor.service -``` - -Caddy: -```shell -sudo journalctl -f -u caddy.service -``` - -VM-Connector: -```shell -sudo docker logs -f vm-connector -``` - -### Common errors - -#### "Network interface eth0 does not exist" - -Did you update the configuration file `/etc/aleph-vm/supervisor.env` with `ALEPH_VM_NETWORK_INTERFACE` equal to -the default network interface of your server ? - -#### "Aleph Connector unavailable" - -Investigate the installation of the VM-Connector using Docker in step 2. +[[https://docs.aleph.im/nodes/compute/installation/ubuntu-22.04/]] \ No newline at end of file diff --git a/doc/INSTALL.md b/doc/INSTALL.md index 79e8d18cf..d42a9f50e 100644 --- a/doc/INSTALL.md +++ b/doc/INSTALL.md @@ -1,4 +1,2 @@ # Installing Aleph-VM - -- [On Debian 11](./INSTALL-Debian-11.md) -- [On Ubuntu 22.04](./INSTALL-Ubuntu-22.04.md) +see [[ https://docs.aleph.im/nodes/compute/]] \ No newline at end of file