ssh: don't add empty PubkeyAcceptedKeyTypes/HostKeyAlgorithms

The options introduced in e2444a433f would generate a broken
ssh config when set to an empty list.

/etc/ssh/ssh_config line 7: Missing argument.
This commit is contained in:
Daiderd Jordan 2018-07-21 12:26:53 +02:00
parent 153d2241c1
commit 3572f89bbe
No known key found for this signature in database
GPG key ID: D02435D05B810C96

View file

@ -211,8 +211,8 @@ in
ForwardX11 ${if cfg.forwardX11 then "yes" else "no"} ForwardX11 ${if cfg.forwardX11 then "yes" else "no"}
PubkeyAcceptedKeyTypes ${concatStringsSep "," cfg.pubkeyAcceptedKeyTypes} ${optionalString (cfg.pubkeyAcceptedKeyTypes != []) PubkeyAcceptedKeyTypes "${concatStringsSep "," cfg.pubkeyAcceptedKeyTypes}"}
HostKeyAlgorithms ${concatStringsSep "," cfg.hostKeyAlgorithms} ${optionalString (cfg.hostKeyAlgorithms != []) HostKeyAlgorithms "${concatStringsSep "," cfg.hostKeyAlgorithms}"}
${cfg.extraConfig} ${cfg.extraConfig}
''; '';