From: Alyssa Rosenzweig Date: Mon, 25 Jun 2018 19:41:25 +0000 (-0400) Subject: Fix TTY implementation X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=e51c7dbc36a200fe86a3d48ce2828487b27c5142;p=libremanage.git Fix TTY implementation --- diff --git a/config.json b/config.json index 9f3e0bd..bed78a7 100644 --- a/config.json +++ b/config.json @@ -3,7 +3,7 @@ "web2": { "manager": "myboard", "tty": { - "file": "/dev/ttyUSB0", + "file": "/dev/ttyO0", "baud": 115200 }, "power": { diff --git a/libremanage.py b/libremanage.py index f28cd97..f72c598 100644 --- a/libremanage.py +++ b/libremanage.py @@ -41,7 +41,7 @@ import subprocess def open_ssh(server, command): config = server["ssh"] - subprocess.run(["ssh", config["username"] + "@" + config["host"], "-p", str(config["port"]), command]) + subprocess.run(["ssh", "-t", config["username"] + "@" + config["host"], "-p", str(config["port"]), command]) def die_with_usage(message): print(message) @@ -84,7 +84,7 @@ COMMANDS = { # TTY access (or keyboard if wired as such) - "tty": lambda s: open_ssh(s, "screen " + s["tty"]["file"] + str(s["tty"]["baud"])), + "tty": lambda s: open_ssh(s, "screen " + s["tty"]["file"] + " " + str(s["tty"]["baud"])), # SSH sanity tests