mirror of
https://github.com/Cyrix126/gupaxx.git
synced 2024-12-22 14:49:21 +00:00
feat: more log for API request xmrig/xmrig-proxy
This commit is contained in:
parent
a7b6a10485
commit
cc037096ee
2 changed files with 5 additions and 2 deletions
|
@ -27,7 +27,10 @@ pub async fn update_xmrig_config(
|
||||||
let mut config = request.send().await?.json::<Value>().await?;
|
let mut config = request.send().await?.json::<Value>().await?;
|
||||||
// modify node configuration
|
// modify node configuration
|
||||||
let uri = [node.url(), ":".to_string(), node.port()].concat();
|
let uri = [node.url(), ":".to_string(), node.port()].concat();
|
||||||
info!("replace xmrig config with node {}", uri);
|
info!(
|
||||||
|
"replace xmrig from api url {api_uri} config with node {}",
|
||||||
|
uri
|
||||||
|
);
|
||||||
*config
|
*config
|
||||||
.pointer_mut("/pools/0/url")
|
.pointer_mut("/pools/0/url")
|
||||||
.ok_or_else(|| anyhow!("pools/0/url does not exist in xmrig config"))? = uri.into();
|
.ok_or_else(|| anyhow!("pools/0/url does not exist in xmrig config"))? = uri.into();
|
||||||
|
|
|
@ -283,7 +283,7 @@ pub(crate) async fn algorithm(
|
||||||
// request XMrig to mine on P2pool
|
// request XMrig to mine on P2pool
|
||||||
// if share is in PW,
|
// if share is in PW,
|
||||||
let msg_xmrig_or_xp = if xp_alive { "XMRig-Proxy" } else { "XMRig" };
|
let msg_xmrig_or_xp = if xp_alive { "XMRig-Proxy" } else { "XMRig" };
|
||||||
|
info!("xp alive: {:?}", xp_alive);
|
||||||
let api_url = api_url_xmrig(xp_alive, true);
|
let api_url = api_url_xmrig(xp_alive, true);
|
||||||
if share > 0 {
|
if share > 0 {
|
||||||
debug!("Xvb Process | Algorithm share is in current window");
|
debug!("Xvb Process | Algorithm share is in current window");
|
||||||
|
|
Loading…
Reference in a new issue