diff --git a/README b/README index 9ca589d..9cbe845 100644 --- a/README +++ b/README @@ -17,6 +17,140 @@ node app.js # if you used pm2, you can use this command pm2 start app.js --name -- +# config like this +// this file please use .conf +{ + "master":{ + "pooldb":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "sharesdb":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "distribution":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "hashrate":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "users_addresses":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "balance":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + } + }, + "slave":{ + "pooldb_slave":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "sharesdb_slave":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + } + }, + "redis_options":{ + "redis1":{ + "host":"", + "port":, + "db":, + "connectTimeout": + } + }, + "node_options":{ + "node1":{ + "rpcUser":"", + "rpcPassword":"", + "rpcPort":, + "rpcHost":"" + }, + "node2":{ + "rpcUser":"", + "rpcPassword":"", + "rpcPort":, + "rpcHost":"" + } + }, + "retry_options":{ + "node":{ + "max_retries":, + "retry_delay": + } + }, + "REPORT_ADDRESS":"", + "MAX_MATURE":, + "distribution_conf":{ + "PPLNS_SIZE":, + "MODEL_PERCENT":{ + "SCORE":, + "PPLNS":, + "PROPDIF": + }, + "SCORE_PERCENT":{ + "HASHRATE":, + "STDDEVS": + }, + "POOL_FEE": + } +} + + + ############# pm2 start common ############# pm2 start app.js --name nexa-hashratev2 -- hashrate nexa pm2 start app.js --name nexa-reportv2 -- report nexa diff --git a/config/example.txt b/config/example.txt new file mode 100644 index 0000000..32b85d7 --- /dev/null +++ b/config/example.txt @@ -0,0 +1,130 @@ +// this file please use .conf +{ + "master":{ + "pooldb":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "sharesdb":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "distribution":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "hashrate":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "users_addresses":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "balance":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + } + }, + "slave":{ + "pooldb_slave":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + }, + "sharesdb_slave":{ + "host": "", + "user": "", + "password": "", + "database": "", + "port":, + "waitForConnections": true, + "connectionLimit": 20, + "queueLimit": 0 + } + }, + "redis_options":{ + "redis1":{ + "host":"", + "port":, + "db":, + "connectTimeout": + } + }, + "node_options":{ + "node1":{ + "rpcUser":"", + "rpcPassword":"", + "rpcPort":, + "rpcHost":"" + }, + "node2":{ + "rpcUser":"", + "rpcPassword":"", + "rpcPort":, + "rpcHost":"" + } + }, + "retry_options":{ + "node":{ + "max_retries":, + "retry_delay": + } + }, + "REPORT_ADDRESS":"", + "MAX_MATURE":, + "distribution_conf":{ + "PPLNS_SIZE":, + "MODEL_PERCENT":{ + "SCORE":, + "PPLNS":, + "PROPDIF": + }, + "SCORE_PERCENT":{ + "HASHRATE":, + "STDDEVS": + }, + "POOL_FEE": + } +} \ No newline at end of file