forked from poz/niksos
ssh changes
This commit is contained in:
parent
c55e8210e8
commit
8d6502a77b
4 changed files with 34 additions and 7 deletions
|
@ -68,7 +68,6 @@ in
|
|||
sessionVariables = {
|
||||
TERM = "foot";
|
||||
EDITOR = "nvim";
|
||||
SSH_AUTH_SOCK = "\$XDG_RUNTIME_DIR/ssh-agent.socket";
|
||||
|
||||
GTK_IM_MODULE = "fcitx";
|
||||
QT_IM_MODULE = "fcitx";
|
||||
|
@ -115,10 +114,6 @@ in
|
|||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
};
|
||||
openssh = {
|
||||
enable = true;
|
||||
settings.PasswordAuthentication = true;
|
||||
};
|
||||
greetd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
|
@ -128,6 +123,7 @@ in
|
|||
};
|
||||
};
|
||||
blueman.enable = true;
|
||||
mullvad-vpn.enable = true;
|
||||
};
|
||||
|
||||
hardware = {
|
||||
|
|
|
@ -3,8 +3,6 @@
|
|||
pkgs,
|
||||
...
|
||||
}: {
|
||||
services.mullvad-vpn.enable = true;
|
||||
|
||||
systemd.services."mullvad-daemon".postStart = let
|
||||
mullvad = config.services.mullvad-vpn.package;
|
||||
in ''
|
||||
|
|
10
hosts/niks/ssh/default.nix
Normal file
10
hosts/niks/ssh/default.nix
Normal file
|
@ -0,0 +1,10 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
settings.PasswordAuthentication = false;
|
||||
};
|
||||
}
|
23
hosts/niks/ssh/ssh-agent.nix
Normal file
23
hosts/niks/ssh/ssh-agent.nix
Normal file
|
@ -0,0 +1,23 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
systemd.user.services.ssh-agent = {
|
||||
enable = true;
|
||||
description = "SSH key agent";
|
||||
serviceConfig = {
|
||||
Type = "simple";
|
||||
ExecStart = "${pkgs.openssh}/bin/ssh-agent -D -a $SSH_AUTH_SOCK";
|
||||
};
|
||||
environment = {
|
||||
SSH_AUTH_SOCK = "%t/ssh-agent.socket";
|
||||
DISPLAY = ":0";
|
||||
};
|
||||
wantedBy = [ "default.target" ];
|
||||
};
|
||||
|
||||
environment.sessionVariables = {
|
||||
SSH_AUTH_SOCK = "\$XDG_RUNTIME_DIR/ssh-agent.socket";
|
||||
};
|
||||
}
|
Loading…
Reference in a new issue