use ssh keys instead of password
This commit is contained in:
parent
ed720cc9dc
commit
30cc1f42b4
4 changed files with 40 additions and 2 deletions
|
@ -1,6 +1,10 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
let
|
||||
keys = import ./authorizedKeys.nix;
|
||||
fetchSSH = (host: lib._.getSSH host keys);
|
||||
fetchSSHKeys = map fetchSSH;
|
||||
in {
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./webapps/default.nix
|
||||
|
@ -20,6 +24,10 @@
|
|||
conf = {
|
||||
packages = with pkgs; [ bat tree micro duf ];
|
||||
extraGroups = [ "wheel" "dotfiles" ];
|
||||
openssh.authorizedKeys.keys = fetchSSHKeys [
|
||||
"reidlab@rei-pc"
|
||||
"reidlab@rei-phone"
|
||||
];
|
||||
};
|
||||
|
||||
homeConf.home = {
|
||||
|
@ -39,7 +47,7 @@
|
|||
services = {
|
||||
ssh = {
|
||||
enable = true;
|
||||
requirePassword = true;
|
||||
requirePassword = false;
|
||||
};
|
||||
|
||||
postgres.enable = true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue