mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-04-19 07:29:46 +02:00
feat(ssh): Using SSH over the HTTPS port for GitHub, refactor ssh config (#187)
This commit is contained in:
@@ -82,7 +82,7 @@
|
||||
# ```
|
||||
# 2. Never leave the device and never sent over the network.
|
||||
# 2. Or just use hardware security keys like Yubikey/CanoKey.
|
||||
openssh.authorizedKeys.keys = myvars.sshAuthorizedKeys;
|
||||
openssh.authorizedKeys.keys = myvars.mainSshAuthorizedKeys;
|
||||
};
|
||||
|
||||
nix.settings = {
|
||||
|
||||
5
modules/darwin/ssh.nix
Normal file
5
modules/darwin/ssh.nix
Normal file
@@ -0,0 +1,5 @@
|
||||
{myvars, ...}: {
|
||||
services.openssh.enable = false;
|
||||
|
||||
programs.ssh = myvars.networking.ssh;
|
||||
}
|
||||
@@ -39,7 +39,7 @@
|
||||
|
||||
# root's ssh key are mainly used for remote deployment
|
||||
users.users.root = {
|
||||
initialHashedPassword = config.users.users."${myvars.username}".initialHashedPassword;
|
||||
openssh.authorizedKeys.keys = config.users.users."${myvars.username}".openssh.authorizedKeys.keys;
|
||||
inherit (myvars) initialHashedPassword;
|
||||
openssh.authorizedKeys.keys = myvars.mainSshAuthorizedKeys ++ myvars.secondaryAuthorizedKeys;
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user