Edit this page

Worker Node Setup

To set up the Worker node application follow the steps below.

NOTE Configuration files location:

For Node, Hub and Worker:

  • If you run SONM components from binaries, configuration files must be stored in same folder.
  • If you have installed SONM comlonents from DEB package or repository, SONM configuration files are stored in: /etc/sonm

For CLI:

  • No matter how you installed CLI, it's configuration file must be stored in ~/.sonm/cli.yaml
  1. Install Docker CE.
  2. Open the worker.yaml configuration file and set up the following preferencies (if you installed from DEB packages or repository, correct filename is worker-default.yaml).

Parameters to set:

Parameter Type Description
1 hub: ethaddr [email protected] Ethereum address, IP and port of your SONM Hub
2 hub: resolve_endpoints boolean Either "resolve_endpoints: true" or "endpoints" should be provided. If "resolve_endpoints" is set to "true", hub's addresses will be resolved via locator.
3 hub: endpoints list of "IP:port" arguments See "hub: resolve_endpoints" above for details.
4 public_ip_addrs IPs A list of public IP addresses of the worker node (if present). If your worker node has a public IP address, uncomment the setting (delete # prefix) and set it's public IP as a parameter value. If you don't have public IP for worker node, you should configure IPVS on your SONM Hub node to allow consumers to connect to their tasks from the outer Internet.
5 ethereum: key_store string Set up the path to folder with keystore file (UTC/JSON file with access to Rinkeby account where your SONM test tokens are stored). NOTE: You should use the same keystore for all SONM components.
6 ethereum: pass_phrase string The passphrase to access your keystore. You may set the passphrase or leave it blank (in that case you will be asked to enter the pass_phrase every time you start the Worker service).

"Plugins" section:

  • If you want to allow your customers to use docker volumes (i.e. use remote network storage), uncomment all strings in "volume" section.
  • If your worker PC has a graphic controller (NVidia or AMD), uncomment appropriate string in "gpu" section.

Other parameters (no need to change):

Parameter Type Description
1 logging: level number The log level number. Allowed values in range of "-1" (high verbosity) to "3" (most quiet). Default value is "-1".
2 metrics_listen_addr IP:port Embedded metrics service. Do not change.
  1. Save the changes to worker.yaml configuration file.
  2. Run SONM Worker:
  • if you use binaries: ./sonmworker
  • if you installed from DEB package or repository: sudo service sonm-worker restart

If you use binaries and did not specified passphrase in worker.yaml, you will be asked for a passphrase to your keystore file.