home: ssh: setup gpg ssh agent socket forwarding

This commit is contained in:
Antoine Martin 2022-11-15 00:36:30 +01:00
parent 630d511f9f
commit 3227363b37

View file

@ -19,10 +19,23 @@ in {
programs.ssh = { programs.ssh = {
enable = true; enable = true;
matchBlocks = { matchBlocks = let
boreal = {hostname = "boreal.alarsyo.net";}; addGPGAgentForwarding = hostConf:
poseidon = {hostname = "poseidon.alarsyo.net";}; {
pi = { remoteForwards = [
{
# shhhh this is a path but it works
bind.address = "/run/user/1000/gnupg/S.gpg-agent.ssh";
host.address = "/run/user/1000/gnupg/S.gpg-agent.ssh";
}
];
}
// hostConf;
in {
boreal = addGPGAgentForwarding {hostname = "boreal.alarsyo.net";};
hades = addGPGAgentForwarding {hostname = "hades.alarsyo.net";};
poseidon = addGPGAgentForwarding {hostname = "poseidon.alarsyo.net";};
pi = addGPGAgentForwarding {
hostname = "pi.alarsyo.net"; hostname = "pi.alarsyo.net";
user = "pi"; user = "pi";
}; };