From a8a80996462117afea96d13ff15156ae1744ef0f Mon Sep 17 00:00:00 2001 From: Chris Duncan Date: Fri, 22 May 2026 14:16:02 -0700 Subject: [PATCH] Update server instructions. --- README.md | 45 +++++++++++++++++++++++++++++++++------------ 1 file changed, 33 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index e27a51b..e24f4a0 100644 --- a/README.md +++ b/README.md @@ -173,25 +173,46 @@ official Nano node software. The installed command will launch the server in a detached process, and it can also be started manually to customize behavior by executing the server script directly. -#### Environment Variables +#### Configuration -`NANO_POW_DEBUG`: enable additional logging saved to the HOME directory +NanoPow will look for a configuration file in the user home directory at the +location `${HOME}/.nano-pow/config` and read the following variables: -`NANO_POW_EFFORT`: increase or decrease demand on the GPU +- `DEBUG`: enable additional logging saved to the HOME directory +- `EFFORT`: increase or decrease demand on the GPU +- `PORT`: override the default port 5040 -`NANO_POW_PORT`: override the default port 5040 +It will then fall back to environment variables for any values not found in the +config file. The same variable names are used, prefixed with `NANO_POW_`: + +- `NANO_POW_DEBUG`: enable additional logging saved to the HOME directory +- `NANO_POW_EFFORT`: increase or decrease demand on the GPU +- `NANO_POW_PORT`: override the default port 5040 + +Environment variables can also be specified inline at time of execution. + +```console +$ # Launch the server and detach from the current session to run in the background +$ NANO_POW_PORT=8080 nano-pow --server +``` + +```console +$ # View process ID for "NanoPow Server" +$ cat ~/.nano-pow/server.pid +``` + +```console +$ # Display list of server logs +$ ls ~/.nano-pow/logs/ +``` ```console -# Launch the server and detach from the current session -NANO_POW_PORT=8080 nano-pow --server -# View process ID for "NanoPow Server" -cat ~/.nano-pow/server.pid -# Display list of server logs -ls ~/.nano-pow/logs/ -# Find process ID manually -pgrep NanoPow +$ # Find process ID manually +$ pgrep NanoPow ``` +#### Usage + Work is generated or validated by sending an HTTP `POST` request to the configured hostname or IP address of the machine. Some basic help is available via `GET` request. -- 2.52.0