2019-03-15 17:32:23 +00:00
|
|
|
---
|
|
|
|
tags: dontlink
|
|
|
|
sitemap: true
|
|
|
|
---
|
|
|
|
|
|
|
|
# Installing manually on Linux
|
|
|
|
|
|
|
|
Yggdrasil is supported on Linux. You can either [download the latest binary from
|
|
|
|
CircleCI](builds.md) or you can build from source.
|
|
|
|
|
2019-03-15 17:47:53 +00:00
|
|
|
## Download binaries
|
|
|
|
|
|
|
|
Download the relevant Linux `yggdrasil` and `yggdrasilctl` binaries from the
|
|
|
|
[Builds](builds.md) page.
|
|
|
|
|
|
|
|
Copy these into a suitable location:
|
|
|
|
```
|
|
|
|
sudo cp {yggdrasil,yggdrasilctl} /usr/local/bin
|
|
|
|
```
|
|
|
|
|
2019-03-15 17:44:04 +00:00
|
|
|
## Build from source
|
2019-03-15 17:32:23 +00:00
|
|
|
|
|
|
|
Linux has most of the tools needed to build Yggdrasil from source - you just
|
|
|
|
need to install the Go toolchain. Yggdrasil requires Go 1.11 as a minimum.
|
|
|
|
|
|
|
|
- Install [the latest version of Go](https://golang.org/dl/) for your platform
|
|
|
|
- Using [godeb](https://github.com/niemeyer/godeb) to install Go is
|
|
|
|
recommended for Debian-based distributions
|
|
|
|
|
|
|
|
Clone the repository and build:
|
|
|
|
```
|
|
|
|
cd /path/to
|
|
|
|
git clone https://github.com/yggdrasil-network/yggdrasil-go
|
|
|
|
```
|
|
|
|
|
|
|
|
Build Yggdrasil:
|
|
|
|
```
|
|
|
|
cd /path/to/yggdrasil-go
|
|
|
|
./build
|
|
|
|
```
|
|
|
|
|
|
|
|
The build will produce `yggdrasil` and `yggdrasilctl` binaries - copy these
|
|
|
|
into a suitable location:
|
|
|
|
```
|
|
|
|
sudo cp {yggdrasil,yggdrasilctl} /usr/local/bin
|
|
|
|
```
|
|
|
|
|
2019-03-15 17:44:04 +00:00
|
|
|
#### Debug builds
|
2019-03-15 17:41:28 +00:00
|
|
|
|
2019-03-15 17:32:23 +00:00
|
|
|
You can create a debug build by running `./build -d` instead of
|
|
|
|
`./build`. Debug builds contain profiling code as well as additional debugging
|
|
|
|
symbols. They are likely to be larger files as a result.
|
|
|
|
|
2019-03-15 17:44:04 +00:00
|
|
|
## Install systemd service
|
2019-03-15 17:32:23 +00:00
|
|
|
|
|
|
|
systemd service scripts are included in the `contrib/systemd/` folder so that it
|
|
|
|
runs automatically in the background (using `/etc/yggdrasil.conf` for
|
|
|
|
configuration).
|
|
|
|
|
|
|
|
Create the `yggdrasil` group on your system - the `systemd` service will run
|
|
|
|
with this group:
|
|
|
|
```
|
|
|
|
sudo groupadd --system yggdrasil
|
|
|
|
```
|
|
|
|
|
|
|
|
Copy the service files:
|
|
|
|
```
|
|
|
|
sudo cp contrib/systemd/yggdrasil.service /etc/systemd/system
|
|
|
|
sudo systemctl daemon-reload
|
|
|
|
```
|
|
|
|
|
|
|
|
Enable and start Yggdrasil:
|
|
|
|
```
|
|
|
|
sudo systemctl enable yggdrasil
|
|
|
|
sudo systemctl start yggdrasil
|
|
|
|
```
|
|
|
|
|
|
|
|
Once installed as a systemd service, you can read the `yggdrasil` output using
|
|
|
|
`systemctl` or `journalctl`:
|
|
|
|
```
|
|
|
|
systemctl status yggdrasil
|
|
|
|
journalctl -u yggdrasil
|
|
|
|
```
|
|
|
|
|
2019-03-15 17:44:04 +00:00
|
|
|
## Generate configuration
|
2019-03-15 17:32:23 +00:00
|
|
|
|
|
|
|
Generate an initial Yggdrasil configuration file:
|
|
|
|
```
|
|
|
|
sudo yggdrasil -genconf > /etc/yggdrasil.conf
|
|
|
|
```
|
|
|
|
|
|
|
|
You can make changes to this file as described in the
|
|
|
|
[Configuration](configuration.md) page.
|
|
|
|
|
2019-03-15 17:44:04 +00:00
|
|
|
## After installation
|
2019-03-15 17:32:23 +00:00
|
|
|
|
2021-11-11 21:46:55 +00:00
|
|
|
Read the [Linux platform page](configuration.md) page for further
|
2019-03-15 17:32:23 +00:00
|
|
|
information about Linux platform support.
|