aboutsummaryrefslogtreecommitdiff
path: root/src/connection
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2021-04-18 12:40:10 -0700
committerSean Whitton <spwhitton@spwhitton.name>2021-04-18 12:43:13 -0700
commitb144e2d3dcaaf8512388201ec61347e925cf75d2 (patch)
tree69e126321a0abf2ac8ddccf7a766664f9282a244 /src/connection
parent42b390533e1faafe7c5cbb23eb0b39315b403dca (diff)
downloadconsfigurator-b144e2d3dcaaf8512388201ec61347e925cf75d2.tar.gz
:SSH connection: fix broken ssh -fN
- Previous command did not include the username. - In some scenarios ssh -fN does not exit, and we can achieve our purpose of confirming that we can authenticate just by calling the ":" builtin. Signed-off-by: Sean Whitton <spwhitton@spwhitton.name>
Diffstat (limited to 'src/connection')
-rw-r--r--src/connection/ssh.lisp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/connection/ssh.lisp b/src/connection/ssh.lisp
index e885ba9..eb132f3 100644
--- a/src/connection/ssh.lisp
+++ b/src/connection/ssh.lisp
@@ -24,8 +24,9 @@
user)
(declare (ignore remaining))
(informat 1 "~&Establishing SSH connection to ~A" hop)
- (mrun "ssh" "-fN" hop)
- (make-instance 'ssh-connection :hostname hop :user user))
+ (let ((connection (make-instance 'ssh-connection :hostname hop :user user)))
+ (mrun "ssh" (ssh-host connection) ":")
+ connection))
(defclass ssh-connection (shell-wrap-connection)
((hostname