aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJakob L. Kreuze <zerodaysfordays@sdf.lonestar.org>2019-07-05 14:54:32 -0400
committerChristopher Lemmer Webber <cwebber@dustycloud.org>2019-07-06 02:09:58 -0400
commita9b09ed7764762f93c1a8b7c96769b9da72dc8c4 (patch)
tree39bc16372290f01ee06103b08ad9479e3e8810dd
parentcce7b037084fe6680803850aed249950e0fdba09 (diff)
downloadguix-a9b09ed7764762f93c1a8b7c96769b9da72dc8c4.tar
guix-a9b09ed7764762f93c1a8b7c96769b9da72dc8c4.tar.gz
ssh: Add 'identity' keyword to 'open-ssh-session'.
* guix/ssh.scm (open-ssh-session): Add 'identity' keyword argument.
-rw-r--r--guix/ssh.scm10
1 files changed, 6 insertions, 4 deletions
diff --git a/guix/ssh.scm b/guix/ssh.scm
index 9b9baf54ea..ede00133c8 100644
--- a/guix/ssh.scm
+++ b/guix/ssh.scm
@@ -57,12 +57,14 @@
(define %compression
"zlib@openssh.com,zlib")
-(define* (open-ssh-session host #:key user port
+(define* (open-ssh-session host #:key user port identity
(compression %compression))
- "Open an SSH session for HOST and return it. When USER and PORT are #f, use
-default values or whatever '~/.ssh/config' specifies; otherwise use them.
-Throw an error on failure."
+ "Open an SSH session for HOST and return it. IDENTITY specifies the file
+name of a private key to use for authenticating with the host. When USER,
+PORT, or IDENTITY are #f, use default values or whatever '~/.ssh/config'
+specifies; otherwise use them. Throw an error on failure."
(let ((session (make-session #:user user
+ #:identity identity
#:host host
#:port port
#:timeout 10 ;seconds