diff --git a/.gitignore b/.gitignore index f104bcfa9..341e3cd47 100644 --- a/.gitignore +++ b/.gitignore @@ -12,3 +12,4 @@ lcov.info *.py **/conf/** cobertura.xml +/roles/*/*-config.toml diff --git a/roles/jd-client/config-examples/proxy-config-hosted-example.toml b/roles/jd-client/config-examples/jdc-config-hosted-example.toml similarity index 100% rename from roles/jd-client/config-examples/proxy-config-hosted-example.toml rename to roles/jd-client/config-examples/jdc-config-hosted-example.toml diff --git a/roles/jd-client/config-examples/proxy-config-local-example.toml b/roles/jd-client/config-examples/jdc-config-local-example.toml similarity index 100% rename from roles/jd-client/config-examples/proxy-config-local-example.toml rename to roles/jd-client/config-examples/jdc-config-local-example.toml diff --git a/roles/jd-client/jdc-config.toml b/roles/jd-client/jdc-config.toml deleted file mode 100644 index 160f93a9e..000000000 --- a/roles/jd-client/jdc-config.toml +++ /dev/null @@ -1,63 +0,0 @@ -# SRI JDC config -downstream_address = "0.0.0.0" -downstream_port = 34265 - -# Version support -max_supported_version = 2 -min_supported_version = 2 - -# Minimum extranonce2 size for downstream -# Max value: 16 (leaves 0 bytes for search space splitting of downstreams) -# Max value for CGminer: 8 -# Min value: 2 -min_extranonce2_size = 8 - -# Withhold -withhold = false -test_only_do_not_send_solution_to_tp = false - -# Auth keys for open encrypted connection downstream -authority_public_key = "3VANfft6ei6jQq1At7d8nmiZzVhBFS4CiQujdgim1ign" -authority_secret_key = "7qbpUjScc865jyX2kiB4NVJANoC7GA7TAJupdzXWkc62" -cert_validity_sec = 3600 - -# How many time the JDC try to reinitialize itself after a failure -retry = 10 - -# Template Provider config -# Local TP (this is pointing to localhost so you must run a TP locally for this configuration to work) -tp_address = "127.0.0.1:8442" -# Hosted testnet TP -#tp_address = "89.116.25.191:8442" -tp_authority_pub_key = "3VANfft6ei6jQq1At7d8nmiZzVhBFS4CiQujdgim1ign" -# Hosted regtest TP -# tp_address = "75.119.150.111:8442" - -# Solo Mining config -# List of coinbase outputs used to build the coinbase tx in case of Solo Mining (as last-resort solution of the pools fallback system) -# ! Put your Extended Public Key or Script as output_script_value ! -# ! Right now only one output is supported, so comment all the ones you don't need ! -# For P2PK, P2PKH, P2WPKH, P2TR a BIP32 extended public key is needed -coinbase_outputs = [ - { output_script_type = "P2WPKH", output_script_value = "036adc3bdf21e6f9a0f0fb0066bf517e5b7909ed1563d6958a10993849a7554075" }, -] - -[timeout] -unit = "secs" -value = 1 - -# List of upstreams (JDS) used as backup endpoints -# In case of shares refused by the JDS, the fallback system will propose the same job to the next upstream in this list -[[upstreams]] -authority_pubkey = "3VANfft6ei6jQq1At7d8nmiZzVhBFS4CiQujdgim1ign" -pool_address = "127.0.0.1:34254" -jd_address = "127.0.0.1:34264" -# Pool signature (string to be included in coinbase tx) -pool_signature = "Stratum v2 SRI Pool" - -# [[upstreams]] -# authority_pubkey = "2di19GHYQnAZJmEpoUeP7C3Eg9TCcksHr23rZCC83dvUiZgiDL" -# pool_address = "127.0.0.1:34254" -# jd_address = "127.0.0.1:34264" -# Pool signature (string to be included in coinbase tx) -# pool_signature = "Stratum v2 SRI Pool" diff --git a/roles/jd-server/jds-config.toml b/roles/jd-server/jds-config.toml deleted file mode 100644 index 803493fa5..000000000 --- a/roles/jd-server/jds-config.toml +++ /dev/null @@ -1,20 +0,0 @@ -# SRI Pool config -authority_public_key = "3VANfft6ei6jQq1At7d8nmiZzVhBFS4CiQujdgim1ign" -authority_secret_key = "7qbpUjScc865jyX2kiB4NVJANoC7GA7TAJupdzXWkc62" -cert_validity_sec = 3600 - -# List of coinbase outputs used to build the coinbase tx -# ! Right now only one output is supported, so comment all the ones you don't need ! -# For P2PK, P2PKH, P2WPKH, P2TR a BIP32 extended public key is needed -coinbase_outputs = [ - { output_script_type = "P2WPKH", output_script_value = "036adc3bdf21e6f9a0f0fb0066bf517e5b7909ed1563d6958a10993849a7554075" }, -] - -# SRI Pool JD config -listen_jd_address = "0.0.0.0:34264" -# RPC config for mempool (it can be also the same TP if correctly configured) -core_rpc_url = "http://127.0.0.1" -#core_rpc_port = 18443 -core_rpc_port = 18332 -core_rpc_user = "username" -core_rpc_pass = "password" diff --git a/roles/mining-proxy/proxy-config-example.toml b/roles/mining-proxy/config-examples/proxy-config-example.toml similarity index 100% rename from roles/mining-proxy/proxy-config-example.toml rename to roles/mining-proxy/config-examples/proxy-config-example.toml diff --git a/roles/mining-proxy/proxy-config.toml b/roles/mining-proxy/proxy-config.toml deleted file mode 100644 index d38aabf55..000000000 --- a/roles/mining-proxy/proxy-config.toml +++ /dev/null @@ -1,15 +0,0 @@ -upstreams = [ - { channel_kind = "Extended", address = "127.0.0.1", port = 34265, pub_key = "3VANfft6ei6jQq1At7d8nmiZzVhBFS4CiQujdgim1ign"}, - # { channel_kind = "Group", address = "127.0.0.1", port = 34254, pub_key = "3VANfft6ei6jQq1At7d8nmiZzVhBFS4CiQujdgim1ign"}, -] -listen_address = "127.0.0.1" -listen_mining_port = 34255 -max_supported_version = 2 -min_supported_version = 2 -downstream_share_per_minute = 1 -coinbase_reward_sat = 5_000_000_000 -# This value is used by the proxy to communicate to the pool the expected hash rate when we open an -# extended channel, based on it the pool will set a target for the channel -expected_total_downstream_hr = 10_000 -# If set to true the proxy will try to reconnect to an upstream that drop the connection -reconnect = true diff --git a/roles/pool/config.toml b/roles/pool/config.toml deleted file mode 100644 index d2f36743e..000000000 --- a/roles/pool/config.toml +++ /dev/null @@ -1,30 +0,0 @@ -# SRI Pool config -authority_public_key = "3VANfft6ei6jQq1At7d8nmiZzVhBFS4CiQujdgim1ign" -authority_secret_key = "7qbpUjScc865jyX2kiB4NVJANoC7GA7TAJupdzXWkc62" -cert_validity_sec = 3600 -test_only_listen_adress_plain = "0.0.0.0:34250" -listen_address = "0.0.0.0:34254" - -# List of coinbase outputs used to build the coinbase tx -# ! Right now only one output is supported, so comment all the ones you don't need ! -# For P2PK, P2PKH, P2WPKH, P2TR a public key is needed. For P2SH and P2WSH, a redeem script is needed. -coinbase_outputs = [ - #{ output_script_type = "P2PK", output_script_value = "0372c47307e5b75ce365daf835f226d246c5a7a92fe24395018d5552123354f086" }, - #{ output_script_type = "P2PKH", output_script_value = "0372c47307e5b75ce365daf835f226d246c5a7a92fe24395018d5552123354f086" }, - #{ output_script_type = "P2SH", output_script_value = "00142ef89234bc95136eb9e6fee9d32722ebd8c1f0ab" }, - #{ output_script_type = "P2WSH", output_script_value = "00142ef89234bc95136eb9e6fee9d32722ebd8c1f0ab" }, - { output_script_type = "P2WPKH", output_script_value = "036adc3bdf21e6f9a0f0fb0066bf517e5b7909ed1563d6958a10993849a7554075" }, - #{ output_script_type = "P2TR", output_script_value = "036adc3bdf21e6f9a0f0fb0066bf517e5b7909ed1563d6958a10993849a7554075" }, -] - -# Pool signature (string to be included in coinbase tx) -pool_signature = "Stratum v2 SRI Pool" - -# Template Provider config -# Local TP (this is pointing to localhost so you must run a TP locally for this configuration to work) -#tp_address = "127.0.0.1:8442" -# Hosted testnet TP -tp_address = "89.116.25.191:8442" -# Hosted regtest TP -# tp_address = "75.119.150.111:8442" - diff --git a/roles/pool/pool-config.toml b/roles/pool/pool-config.toml deleted file mode 100644 index 30e150188..000000000 --- a/roles/pool/pool-config.toml +++ /dev/null @@ -1,30 +0,0 @@ - -# SRI Pool config -authority_public_key = "3VANfft6ei6jQq1At7d8nmiZzVhBFS4CiQujdgim1ign" -authority_secret_key = "7qbpUjScc865jyX2kiB4NVJANoC7GA7TAJupdzXWkc62" -cert_validity_sec = 3600 -test_only_listen_adress_plain = "0.0.0.0:34250" -listen_address = "0.0.0.0:34254" - -# List of coinbase outputs used to build the coinbase tx -# ! Right now only one output is supported, so comment all the ones you don't need ! -# For P2PK, P2PKH, P2WPKH, P2TR a public key is needed. For P2SH and P2WSH, a redeem script is needed. -coinbase_outputs = [ - #{ output_script_type = "P2PK", output_script_value = "0372c47307e5b75ce365daf835f226d246c5a7a92fe24395018d5552123354f086" }, - #{ output_script_type = "P2PKH", output_script_value = "0372c47307e5b75ce365daf835f226d246c5a7a92fe24395018d5552123354f086" }, - #{ output_script_type = "P2SH", output_script_value = "00142ef89234bc95136eb9e6fee9d32722ebd8c1f0ab" }, - #{ output_script_type = "P2WSH", output_script_value = "00142ef89234bc95136eb9e6fee9d32722ebd8c1f0ab" }, - { output_script_type = "P2WPKH", output_script_value = "036adc3bdf21e6f9a0f0fb0066bf517e5b7909ed1563d6958a10993849a7554075" }, - #{ output_script_type = "P2TR", output_script_value = "036adc3bdf21e6f9a0f0fb0066bf517e5b7909ed1563d6958a10993849a7554075" }, -] - -# Pool signature (string to be included in coinbase tx) -pool_signature = "Stratum v2 SRI Pool" - -# Template Provider config -# Local TP (this is pointing to localhost so you must run a TP locally for this configuration to work) -#tp_address = "127.0.0.1:8442" -# Hosted testnet TP -tp_address = "89.116.25.191:8442" -# Hosted regtest TP -# tp_address = "75.119.150.111:8442" diff --git a/roles/translator/config-examples/proxy-config-local-jdc-example.toml b/roles/translator/config-examples/tproxy-config-local-jdc-example.toml similarity index 77% rename from roles/translator/config-examples/proxy-config-local-jdc-example.toml rename to roles/translator/config-examples/tproxy-config-local-jdc-example.toml index d71a9f303..fd1ac9237 100644 --- a/roles/translator/config-examples/proxy-config-local-jdc-example.toml +++ b/roles/translator/config-examples/tproxy-config-local-jdc-example.toml @@ -25,13 +25,13 @@ coinbase_reward_sat = 5_000_000_000 # Difficulty params [downstream_difficulty_config] -# hashes/s of the weakest miner that will be connecting -min_individual_miner_hashrate=5_000_000.0 +# hashes/s of the weakest miner that will be connecting (e.g.: 10 Th/s = 10_000_000_000_000.0) +min_individual_miner_hashrate=10_000_000_000_000.0 # target number of shares per minute the miner should be sending shares_per_minute = 6.0 [upstream_difficulty_config] # interval in seconds to elapse before updating channel hashrate with the pool channel_diff_update_interval = 60 -# estimated accumulated hashrate of all downstream miners -channel_nominal_hashrate = 5_000_000.0 +# estimated accumulated hashrate of all downstream miners (e.g.: 10 Th/s = 10_000_000_000_000.0) +channel_nominal_hashrate = 10_000_000_000_000.0 diff --git a/roles/translator/config-examples/proxy-config-local-pool-example.toml b/roles/translator/config-examples/tproxy-config-local-pool-example.toml similarity index 77% rename from roles/translator/config-examples/proxy-config-local-pool-example.toml rename to roles/translator/config-examples/tproxy-config-local-pool-example.toml index 3a1f78cfa..6da9c3a51 100644 --- a/roles/translator/config-examples/proxy-config-local-pool-example.toml +++ b/roles/translator/config-examples/tproxy-config-local-pool-example.toml @@ -25,13 +25,13 @@ coinbase_reward_sat = 5_000_000_000 # Difficulty params [downstream_difficulty_config] -# hashes/s of the weakest miner that will be connecting -min_individual_miner_hashrate=5_000_000.0 +# hashes/s of the weakest miner that will be connecting (e.g.: 10 Th/s = 10_000_000_000_000.0) +min_individual_miner_hashrate=10_000_000_000_000.0 # target number of shares per minute the miner should be sending shares_per_minute = 6.0 [upstream_difficulty_config] # interval in seconds to elapse before updating channel hashrate with the pool channel_diff_update_interval = 60 -# estimated accumulated hashrate of all downstream miners -channel_nominal_hashrate = 5_000_000.0 +# estimated accumulated hashrate of all downstream miners (e.g.: 10 Th/s = 10_000_000_000_000.0) +channel_nominal_hashrate = 10_000_000_000_000.0 diff --git a/roles/translator/proxy-config.toml b/roles/translator/proxy-config.toml deleted file mode 100644 index b83fd15e7..000000000 --- a/roles/translator/proxy-config.toml +++ /dev/null @@ -1,39 +0,0 @@ -# Braiins Pool Upstream Connection -# upstream_authority_pubkey = "u95GEReVMjK6k5YqiSFNqqTnKU4ypU2Wm8awa6tmbmDmk1bWt" -# upstream_address = "18.196.32.109" -# upstream_port = 3336 - -# Local SRI Pool Upstream Connection -upstream_address = "127.0.0.1" -upstream_port = 34254 -upstream_authority_pubkey = "3VANfft6ei6jQq1At7d8nmiZzVhBFS4CiQujdgim1ign" - -# Local Mining Device Downstream Connection -downstream_address = "0.0.0.0" -downstream_port = 34255 - -# Version support -max_supported_version = 2 -min_supported_version = 2 - -# Minimum extranonce2 size for downstream -# Max value: 16 (leaves 0 bytes for search space splitting of downstreams) -# Max value for CGminer: 8 -# Min value: 2 -min_extranonce2_size = 8 -coinbase_reward_sat = 5_000_000_000 - -# Difficulty params -[downstream_difficulty_config] -# hashes/s of the weakest miner that will be connecting -min_individual_miner_hashrate=500_000.0 -# minimum number of shares needed before a mining.set_difficulty is sent for updating targets -miner_num_submits_before_update=5 -# target number of shares per minute the miner should be sending -shares_per_minute = 6.0 - -[upstream_difficulty_config] -# interval in seconds to elapse before updating channel hashrate with the pool -channel_diff_update_interval = 10 -# estimated accumulated hashrate of all downstream miners -channel_nominal_hashrate = 50_000.0