Run a node

Configuration

The settings a node reads, and the one folder it keeps.

On this page

Settings

Set these as environment variables on the container.

SettingDefaultWhat it does
HOPBITS_DAILY_MB200The daily cap for measurement traffic, in whole MB. The lowest value is 1. A value above 200 is brought back to 200.
HOPBITS_NETWORK_MODENonehost or bridge: the Docker network the node runs on.
HOPBITS_DISABLE_KINDSNoneChecks this node should not run, as a comma-separated list of http, tcp_connect and icmp_ping. At least one has to stay on.
HOPBITS_AUTO_UPDATEtrueSet it to false and the node stops updating itself.
HOPBITS_LOG_LEVELinfodebug, info, warn or error.
HOPBITS_ENROLLNoneAn enrolment token. See Enrol a fleet.
HOPBITS_GATEWAYwss://api.hopbits.io/v1/nodeOutbound TLS WebSocket gateway endpoint. Leave unset unless instructed otherwise.

For example, a node with half the daily cap that leaves ping checks to others:

Docker CLI
sudo docker run -d \
  --name hopbits-agent \
  --restart=always \
  --cap-drop ALL \
  --security-opt no-new-privileges:true \
  --network host \
  -e HOPBITS_NETWORK_MODE=host \
  -e HOPBITS_DAILY_MB=100 \
  -e HOPBITS_DISABLE_KINDS=icmp_ping \
  -v hopbits-data:/var/lib/hopbits \
  hopbits/agent:local

What the node keeps

Everything lives in /var/lib/hopbits inside the container. That folder is the hopbits-data volume.

FileWhat it is
node.keyThe node's identity. The node ID comes from this key.
state.jsonWhat the node remembers between starts.
traffic.jsonHow much of today's cap has been used.
pending/Results the network has not confirmed yet, kept for up to 24 hours.
jobs.logThe last 100 jobs the node ran.