Appearance
Node Daemon
The node daemon is the main production binary that runs your service as a persistent process.
Building
Enable the node binary at CMake configure time:
bash
mkdir build && cd build
cmake .. -DCMAKE_BUILD_TYPE=Debug -DENABLE_BUILD_NODE=ON
make -j$(nproc)The -DENABLE_BUILD_NODE=ON flag produces the node executable.
Typical Workflow
- Build the node binary.
- Create a
config.jsonwith your service settings. - Run
./node --config config.json. - The node listens for client connections and participates in the mesh.
Running
bash
./node --config /etc/my-service/config.jsonThe daemon reads its configuration from the JSON file specified via --config. Additional command-line flags can override specific config values (e.g., --port 8080).
Command-line Options
| Option | Description |
|---|---|
--config <path> | Path to JSON configuration file. |
--port <port> | Override the client port. |
--node-port <port> | Override the inter-node port. |
--seed <host:port> | Override the seed node address. |
Configuration
The node loads its full configuration from the JSON file. See the Configuration page for the complete reference.