You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
673 B
27 lines
673 B
{ outputs, lib, ... }:
|
|
let
|
|
hostnames = builtins.attrNames outputs.nixosConfigurations;
|
|
in
|
|
{
|
|
programs.ssh = {
|
|
enable = true;
|
|
matchBlocks = {
|
|
net = {
|
|
host = builtins.concatStringsSep " " hostnames;
|
|
forwardAgent = true;
|
|
remoteForwards = [{
|
|
bind.address = ''/%d/.gnupg-sockets/S.gpg-agent'';
|
|
host.address = ''/%d/.gnupg-sockets/S.gpg-agent.extra'';
|
|
}];
|
|
};
|
|
trusted = lib.hm.dag.entryBefore [ "net" ] {
|
|
host = "m7.rs *.m7.rs *.ts.m7.rs";
|
|
forwardAgent = true;
|
|
};
|
|
};
|
|
};
|
|
|
|
home.persistence = {
|
|
"/persist/home/${config.home.username}".directories = [ ".ssh" ];
|
|
};
|
|
}
|
|
|