clan: clan ssh
fix for new installer image
This commit is contained in:
parent
22b767466c
commit
72811d0828
@ -80,15 +80,15 @@ def is_reachable(host: str) -> bool:
|
|||||||
|
|
||||||
|
|
||||||
def connect_ssh_from_json(ssh_data: dict[str, str]) -> None:
|
def connect_ssh_from_json(ssh_data: dict[str, str]) -> None:
|
||||||
for address in ssh_data["local_addresses"]:
|
for address in ssh_data["addrs"]:
|
||||||
log.debug(f"Trying to reach host on: {address}")
|
log.debug(f"Trying to reach host on: {address}")
|
||||||
if is_reachable(address):
|
if is_reachable(address):
|
||||||
ssh(host=address, password=ssh_data["password"])
|
ssh(host=address, password=ssh_data["pass"])
|
||||||
exit(0)
|
exit(0)
|
||||||
else:
|
else:
|
||||||
log.debug(f"Could not reach host on {address}")
|
log.debug(f"Could not reach host on {address}")
|
||||||
log.debug(f'Trying to reach host via torify on {ssh_data["onion_address"]}')
|
log.debug(f'Trying to reach host via torify on {ssh_data["tor"]}')
|
||||||
ssh(host=ssh_data["onion_address"], password=ssh_data["password"], torify=True)
|
ssh(host=ssh_data["tor"], password=ssh_data["pass"], torify=True)
|
||||||
|
|
||||||
|
|
||||||
def main(args: argparse.Namespace) -> None:
|
def main(args: argparse.Namespace) -> None:
|
||||||
|
Loading…
Reference in New Issue
Block a user