GoShimmer Node (Pollen)

Video Tutorial

Soon...

Installation guide (command overview)

1. Create a user for GoShimmer

Code
sudo useradd -s /bin/bash -m shimmer


2. Update package list and install needed packages

Code
sudo apt update && sudo apt install build-essential git snapd -y


3. Install the go package

Code
sudo snap install go --classic


4. Clone GoShimmer repository to local file system

Code
git clone https://github.com/iotaledger/goshimmer.git --branch master /var/lib/goshimmer


5. Change to the GoShimmer directory

Code
cd /var/lib/goshimmer


6. Build shimmer

Code
go build -o shimmer


7. Copy configuration file

Code
sudo cp -r config.default.json config.json


8. Set folder and file permissions for the "shimmer" user

Code
sudo chown -R shimmer:shimmer /var/lib/goshimmer


9. Download the service template

Code
sudo wget https://raw.githubusercontent.com/tanglebay/tutorials/master/goshimmer/shimmer.service -O /lib/systemd/system/shimmer.service


10. Reload the system daemon

Code
sudo systemctl daemon-reload


11. Enable the service of shimmer

Code
sudo systemctl enable shimmer


12. Start shimmer

Code
sudo systemctl start shimmer


13. Access to the dashboard without HTTPS

To get access to the dashboard directly from Shimmer, you need to adjust the address in your Shimmer configuration, to do this open the file once with the following command:

Code
sudo nano /var/lib/goshimmer/config.json

There you must now search for the following section:

Code
  "dashboard": {
    "bindAddress": "127.0.0.1:8081",
    "dev": false,
    "basic_auth": {
      "enabled": false,
      "username": "goshimmer",
      "password": "goshimmer"
    }
  },

and replace "bindAddress": "127.0.0.1:8081", with "bindAddress": "0.0.0:8081",.


Shimmer must then be restarted.

Code
sudo systemctl restart shimmer

(OPTIONAL) Reverse Proxy with SSL

To access the Shimmer Dashboard over a secure SSL connection, you need a reverse proxy. In this step, we will do the setup for this.

It is important that port 80 is enabled to the outside world so that we can apply for a free SSL certificate using Letencrypt.


1. Update packages and install needed packages

Code
sudo apt update && sudo apt install apache2-utils software-properties-common certbot python3-certbot-nginx -y


2. Request certificate from LetEncrypt using Certbot.

You need to replace domain.tld with your own domain (which points to the IP-address of your server)

Code
sudo certbot --nginx -d domain.tld

First you have to enter your email address, this is required and should be set accordingly. Afterwards you have to accept the conditions with A and in the last step you want to receive your own e-mail information, so you choose N there.


3. Download certificate template and replace existing one

Code
sudo rm -rf /etc/nginx/sites-enabled/default && sudo wget https://raw.githubusercontent.com/tanglebay/tutorials/master/goshimmer/nginx.template -O /etc/nginx/sites-enabled/default


4. Open & edit configuration file

Code
sudo nano /etc/nginx/sites-enabled/default

Here you have to press the key combination ALT + R for the search-replace function. Then enter domain.tld for the search and then your domain for the replace. Then select A (All) to replace all entries directly. Finally save the configuration file.


5. Create auth file for the dashboard

Code
sudo touch /etc/nginx/.htpasswd


6. Create auth user for the dashboard

Please replace username with your own user name

Code
sudo htpasswd -B /etc/nginx/.htpasswd username


7. Restart the reverse proxy

Code
sudo systemctl restart 

Now you can access your dashboard from your domain!


Update GoShimmer


1. Stop your goshimmer node

Code
sudo systemctl stop shimmer


2. Update your goshimmer node (you must run this command with the "shimmer" user sudo su shimmer!)

Code
curl -sL https://raw.githubusercontent.com/tanglebay/tutorials/master/goshimmer/update-goshimmer.sh | bash -


2.1 (OPTIONAL) If you want to keep your database and configuration, you can do this with the following command

Code
curl -sL https://raw.githubusercontent.com/tanglebay/tutorials/master/goshimmer/update-goshimmer.sh | bash -s -- -noreset


3. (OPTIONAL) Copy needed configuration data from the backup into the new configuration file. The files can be found in the following directory:

Code
nano /var/lib/goshimmer/backup


4. Start your goshimmer node

Code
sudo systemctl start shimmer