From: "Ludovic Courtès" <ludo@gnu.org>
To: Nicolas Graves <ngraves@ngraves.fr>
Cc: 62461@debbugs.gnu.org
Subject: [bug#62461] Additional ssh configuration options.
Date: Sat, 01 Apr 2023 09:59:25 +0200 [thread overview]
Message-ID: <87fs9kghia.fsf_-_@gnu.org> (raw)
In-Reply-To: <20230326140706.32412-2-ngraves@ngraves.fr> (Nicolas Graves's message of "Sun, 26 Mar 2023 16:07:05 +0200")
Nicolas Graves <ngraves@ngraves.fr> skribis:
> ---
> gnu/home/services/ssh.scm | 49 ++++++++++++++++++++++++++++++++++-----
> 1 file changed, 43 insertions(+), 6 deletions(-)
[...]
> +(define ssh-match-keywords
> + '("canonical" "final" "exec" "host" "originalhost" "user" "localuser"))
Should it be symbols?
> (define-configuration openssh-host
> (name
> - (string)
> - "Name of this host declaration.")
> + maybe-string
> + "Name of this host declaration. A @code{openssh-host} must define only
> +@code{name} or @code{match-criteria}. Use host-name \"*\" for top-level
> +options.")
“Use host name @code{\"*\"} for …”
> + (match-criteria ;TODO implement stricter match-criteria rules
> + maybe-match-criteria
> + "A string where the first element is all or one of
> +@code{ssh-match-keywords}. The rest of the elements are arguments for the
How about: “When specified, this string denotes the set of hosts to
which the entry applies, superseding the @code{host-name} field. Its
first element must be all or one of…”
> (string-append
> - "Host " (openssh-host-name config) "\n"
> + (if (maybe-value-set? (openssh-host-name config))
> + (if (maybe-value-set? (openssh-host-match-criteria config))
> + (error
> + "You must either define name or match-criteria, not both.")
> + (string-append "Host " (openssh-host-name config) "\n"))
> + (if (maybe-value-set? (openssh-host-match-criteria config))
> + (string-append
> + "Match " (string-join (openssh-host-match-criteria config) " ") "\n")
> + (error
> + "You must either define name or match-criteria once.")))
Please report errors as lowercase messages with:
(raise (formatted-message (G_ "…") …))
You can also use ‘&fix-hint’ to provide an additional hint, if needed.
Ludo’.
next prev parent reply other threads:[~2023-04-01 8:00 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-26 13:58 [bug#62461] Additional ssh configuration options Nicolas Graves via Guix-patches via
2023-03-26 14:07 ` [bug#62461] [PATCH 1/3] gnu: home-openssh-configuration: Add field add-keys-to-agent Nicolas Graves via Guix-patches via
2023-03-26 14:07 ` [bug#62461] [PATCH 2/3] gnu: openssh-host: Add option match-criteria Nicolas Graves via Guix-patches via
2023-04-01 7:59 ` Ludovic Courtès [this message]
2023-04-17 15:08 ` [bug#62461] Additional ssh configuration options Nicolas Graves via Guix-patches via
2023-03-26 14:07 ` [bug#62461] [PATCH 3/3] gnu: ssh: Export configuration predicates Nicolas Graves via Guix-patches via
2023-04-01 8:00 ` [bug#62461] Additional ssh configuration options Ludovic Courtès
2023-04-01 7:45 ` Ludovic Courtès
2023-04-20 8:30 ` [bug#62461] [PATCH v2 1/4] gnu: home-openssh-configuration: Add field add-keys-to-agent Nicolas Graves via Guix-patches via
2023-04-20 8:30 ` [bug#62461] [PATCH v2 2/4] gnu: openssh-host: Add option match-criteria Nicolas Graves via Guix-patches via
2023-04-20 8:30 ` [bug#62461] [PATCH v2 3/4] gnu: ssh: Export configuration predicates Nicolas Graves via Guix-patches via
2023-04-20 8:30 ` [bug#62461] [PATCH v2 4/4] gnu: ssh: Export home-ssh-agent variables Nicolas Graves via Guix-patches via
2023-05-14 21:11 ` [bug#62461] Additional ssh configuration options Ludovic Courtès
2023-06-05 12:34 ` [bug#62461] [PATCH v3 1/4] gnu: home-openssh-configuration: Add field add-keys-to-agent Nicolas Graves via Guix-patches via
2023-06-05 12:34 ` [bug#62461] [PATCH v3 2/4] gnu: openssh-host: Add option match-criteria Nicolas Graves via Guix-patches via
2023-06-05 12:34 ` [bug#62461] [PATCH v3 3/4] gnu: ssh: Export configuration predicates Nicolas Graves via Guix-patches via
2023-06-05 12:34 ` [bug#62461] [PATCH v3 4/4] gnu: ssh: Export home-ssh-agent variables Nicolas Graves via Guix-patches via
2023-06-09 21:43 ` bug#62461: Additional ssh configuration options Ludovic Courtès
2023-07-04 20:17 ` [bug#62461] " Josselin Poiret via Guix-patches via
2023-07-21 20:23 ` Nicolas Graves via Guix-patches via
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87fs9kghia.fsf_-_@gnu.org \
--to=ludo@gnu.org \
--cc=62461@debbugs.gnu.org \
--cc=ngraves@ngraves.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).