mirror of
https://github.com/nix-community/home-manager.git
synced 2026-06-05 21:02:51 +00:00
`SSH_AUTH_SOCK` is exported in shells only, which systemd does not inherit from. With this commit, it is also set in systemd such that systemd-managed applications can access the SSH agent by declaring dependencies onto 'sshAuthSock.systemd.socketProviderUnit'. Closes #7971.
26 lines
601 B
Nix
26 lines
601 B
Nix
{
|
|
programs.bash.enable = true;
|
|
programs.fish.enable = true;
|
|
programs.nushell.enable = true;
|
|
programs.zsh.enable = true;
|
|
|
|
sshAuthSock.enable = false;
|
|
|
|
nmt.script = ''
|
|
assertFileNotRegex \
|
|
home-files/.profile \
|
|
'SSH_AUTH_SOCK'
|
|
assertFileNotRegex \
|
|
home-files/.config/fish/config.fish \
|
|
'SSH_AUTH_SOCK'
|
|
assertFileNotRegex \
|
|
home-files/.config/nushell/config.nu \
|
|
'SSH_AUTH_SOCK'
|
|
assertFileNotRegex \
|
|
home-files/.zshenv \
|
|
'SSH_AUTH_SOCK'
|
|
|
|
assertPathNotExists home-files/.config/systemd/user/set-SSH_AUTH_SOCK.service
|
|
'';
|
|
}
|