aboutsummaryrefslogtreecommitdiffstats
path: root/hosts/common/users
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--hosts/common/users/nipsy/default.nix31
-rw-r--r--hosts/common/users/nipsy/keys/id_arrakis.pub1
-rw-r--r--hosts/common/users/root/default.nix10
3 files changed, 42 insertions, 0 deletions
diff --git a/hosts/common/users/nipsy/default.nix b/hosts/common/users/nipsy/default.nix
new file mode 100644
index 0000000..58ef9b3
--- /dev/null
+++ b/hosts/common/users/nipsy/default.nix
@@ -0,0 +1,31 @@
+{ pkgs, inputs, config, ... }:
+let
+ ifTheyExist = groups: builtins.filter (group: builtins.hasAttr group config.users.groups) groups;
+in
+{
+ users.groups.nipsy.gid = 1000;
+ users.users.nipsy = {
+ description = "Mark Nipper";
+ extraGroups = [
+ "wheel"
+ "audio"
+ "video"
+ ] ++ ifTheyExist [
+ "networkmanager"
+ ];
+ group = "nipsy";
+ home = "/home/nipsy";
+ isNormalUser = true;
+ openssh.authorizedKeys.keys = [
+ (builtins.readFile ./keys/id_arrakis.pub)
+ #(builtins.readFile ./keys/id_other.pub)
+ ];
+
+ packages = [ pkgs.home-manager ];
+ shell = pkgs.zsh;
+ };
+
+ # Import this user's personal/home configurations
+ home-manager.users.nipsy = import ../../../../home/nipsy/${config.networking.hostName}.nix;
+
+}
diff --git a/hosts/common/users/nipsy/keys/id_arrakis.pub b/hosts/common/users/nipsy/keys/id_arrakis.pub
new file mode 100644
index 0000000..38c1d4c
--- /dev/null
+++ b/hosts/common/users/nipsy/keys/id_arrakis.pub
@@ -0,0 +1 @@
+ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIbKppxX6GF88fAfXJZR4ZcPzwopi7TAy+v/dmWso+7f nipsy@arrakis.bitgnome.net
diff --git a/hosts/common/users/root/default.nix b/hosts/common/users/root/default.nix
new file mode 100644
index 0000000..f70f414
--- /dev/null
+++ b/hosts/common/users/root/default.nix
@@ -0,0 +1,10 @@
+{ pkgs, ... }:
+{
+ users.users.root = {
+ openssh.authorizedKeys.keys = [
+ (builtins.readFile ../nipsy/keys/id_arrakis.pub)
+ #(builtins.readFile ./keys/id_other.pub)
+ ];
+ shell = pkgs.zsh;
+ };
+}