bug: fix bosminer.toml writing to use only ssh, no sftp.

This commit is contained in:
Upstream Data
2024-05-03 08:30:51 -06:00
parent b7a81097a4
commit 993b7efeef

View File

@@ -201,9 +201,7 @@ class BOSMiner(BaseMiner):
async with conn: async with conn:
await conn.run("/etc/init.d/bosminer stop") await conn.run("/etc/init.d/bosminer stop")
async with conn.start_sftp_client() as sftp: await conn.run("echo '" + toml_conf + "' > /etc/bosminer.toml")
async with sftp.open("/etc/bosminer.toml", "w+") as file:
await file.write(toml_conf)
await conn.run("/etc/init.d/bosminer start") await conn.run("/etc/init.d/bosminer start")
async def set_power_limit(self, wattage: int) -> bool: async def set_power_limit(self, wattage: int) -> bool: