diff options
author | Alyssa Ross <hi@alyssa.is> | 2019-02-24 01:09:00 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2019-02-24 01:09:00 +0000 |
commit | 072c01a28f865e9487df09aed7ddff328252fb36 (patch) | |
tree | 6df6e652915940255f294ed8998cce1c4c7c2d40 /nixpkgs/nixos/modules/programs/ssh.nix | |
parent | 024b46ff20027c15322e5d868ecec42632556d4b (diff) | |
parent | 969cff2691a02b3d7e5468beda26c482d8986644 (diff) | |
download | nixlib-072c01a28f865e9487df09aed7ddff328252fb36.tar nixlib-072c01a28f865e9487df09aed7ddff328252fb36.tar.gz nixlib-072c01a28f865e9487df09aed7ddff328252fb36.tar.bz2 nixlib-072c01a28f865e9487df09aed7ddff328252fb36.tar.lz nixlib-072c01a28f865e9487df09aed7ddff328252fb36.tar.xz nixlib-072c01a28f865e9487df09aed7ddff328252fb36.tar.zst nixlib-072c01a28f865e9487df09aed7ddff328252fb36.zip |
Merge commit '969cff2691a02b3d7e5468beda26c482d8986644'
Diffstat (limited to 'nixpkgs/nixos/modules/programs/ssh.nix')
-rw-r--r-- | nixpkgs/nixos/modules/programs/ssh.nix | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/nixpkgs/nixos/modules/programs/ssh.nix b/nixpkgs/nixos/modules/programs/ssh.nix index 4640c1d78d20..46965dd35b71 100644 --- a/nixpkgs/nixos/modules/programs/ssh.nix +++ b/nixpkgs/nixos/modules/programs/ssh.nix @@ -88,7 +88,8 @@ in type = types.lines; default = ""; description = '' - Extra configuration text appended to <filename>ssh_config</filename>. + Extra configuration text prepended to <filename>ssh_config</filename>. Other generated + options will be added after a <code>Host *</code> pattern. See <citerefentry><refentrytitle>ssh_config</refentrytitle><manvolnum>5</manvolnum></citerefentry> for help. ''; @@ -203,6 +204,11 @@ in # generation in the sshd service. environment.etc."ssh/ssh_config".text = '' + # Custom options from `extraConfig`, to override generated options + ${cfg.extraConfig} + + # Generated options from other settings + Host * AddressFamily ${if config.networking.enableIPv6 then "any" else "inet"} ${optionalString cfg.setXAuthLocation '' @@ -213,8 +219,6 @@ in ${optionalString (cfg.pubkeyAcceptedKeyTypes != []) "PubkeyAcceptedKeyTypes ${concatStringsSep "," cfg.pubkeyAcceptedKeyTypes}"} ${optionalString (cfg.hostKeyAlgorithms != []) "HostKeyAlgorithms ${concatStringsSep "," cfg.hostKeyAlgorithms}"} - - ${cfg.extraConfig} ''; environment.etc."ssh/ssh_known_hosts".text = knownHostsText; |