ssh: make askPassword an option

By making askPassword an option, desktop environment modules can
override the default x11_ssh_askpassword with their own equivalent for
better integration. For example, KDE 5 uses plasma5.ksshaskpass instead.
This commit is contained in:
Thomas Tuegel 2015-03-11 10:59:02 -05:00
parent 5b5b7aa951
commit 4b10907152

View File

@ -9,7 +9,7 @@ let
cfg = config.programs.ssh;
cfgd = config.services.openssh;
askPassword = "${pkgs.x11_ssh_askpass}/libexec/x11-ssh-askpass";
askPassword = cfg.askPassword;
askPasswordWrapper = pkgs.writeScript "ssh-askpass-wrapper"
''
@ -26,6 +26,12 @@ in
programs.ssh = {
askPassword = mkOption {
type = types.string;
default = "${pkgs.x11_ssh_askpass}/libexec/x11-ssh-askpass";
description = ''Program used by SSH to ask for passwords.'';
};
forwardX11 = mkOption {
type = types.bool;
default = false;