ssh.nix 496 B

1234567891011121314151617181920212223242526272829
  1. { config, ... }:
  2. let
  3. inherit (config.xdg) configHome;
  4. in
  5. {
  6. home.sessionVariables = {
  7. SSH_AUTH_SOCK = "${configHome}/gnupg/S.gpg-agent.ssh";
  8. };
  9. programs.ssh = {
  10. enable = true;
  11. compression = true;
  12. forwardAgent = true;
  13. extraConfig = ''
  14. StreamLocalBindUnlink yes
  15. '';
  16. matchBlocks = {
  17. modgud = {
  18. hostname = "modgud.t5.st";
  19. user = "thomas";
  20. };
  21. "github.com".user = "git";
  22. github.hostname = "github.com";
  23. };
  24. };
  25. }