summaryrefslogtreecommitdiff
path: root/hosts
diff options
context:
space:
mode:
authorsinanmohd <sinan@sinanmohd.com>2024-01-08 23:09:42 +0530
committersinanmohd <sinan@sinanmohd.com>2024-01-08 23:29:53 +0530
commitf8cea6f6c8a8ce35533d7fa978dbff8cd5427b7c (patch)
treeb87d5da18c6f86d3a931a88370f41421833e9814 /hosts
parent119d8d504f435b552e548a9130ae96a2a3721dff (diff)
modules/userdata: refactor
Diffstat (limited to 'hosts')
-rw-r--r--hosts/cez/configuration.nix15
-rw-r--r--hosts/cez/modules/wayland.nix31
-rw-r--r--hosts/kay/modules/sftp.nix5
3 files changed, 28 insertions, 23 deletions
diff --git a/hosts/cez/configuration.nix b/hosts/cez/configuration.nix
index 2df69ef..05c3b9f 100644
--- a/hosts/cez/configuration.nix
+++ b/hosts/cez/configuration.nix
@@ -39,12 +39,13 @@ in
getty.autologinUser = user;
};
- userdata.packages = with pkgs; [
- geoipWithDatabase
- ffmpeg
- (pass.withExtensions (exts: [ exts.pass-otp ]))
- ];
-
programs.adb.enable = true;
- userdata.groups = [ "adbusers" ];
+ users.users.${user} = {
+ extraGroups = [ "adbusers" ];
+ packages = with pkgs; [
+ geoipWithDatabase
+ ffmpeg
+ (pass.withExtensions (exts: [ exts.pass-otp ]))
+ ];
+ };
}
diff --git a/hosts/cez/modules/wayland.nix b/hosts/cez/modules/wayland.nix
index 69e738a..085c950 100644
--- a/hosts/cez/modules/wayland.nix
+++ b/hosts/cez/modules/wayland.nix
@@ -9,7 +9,6 @@ in
bemenu
sway
i3status
- pinentry-bemenu
swaylock
swayidle
swaybg
@@ -19,18 +18,23 @@ in
xdg-utils
libnotify
];
- users.users.${user}.packages = with pkgs; [
- zathura
- mpv
- imv
- wtype
- qemu
- OVMFFull
- grim
- slurp
- tor-browser-bundle-bin
- element-desktop-wayland
- ];
+
+ users.users.${user} = {
+ extraGroups = [ "seat" ];
+ packages = with pkgs; [
+ zathura
+ mpv
+ imv
+ wtype
+ qemu
+ OVMFFull
+ grim
+ slurp
+ tor-browser-bundle-bin
+ element-desktop-wayland
+ pinentry-bemenu
+ ];
+ };
# font
fonts = {
@@ -73,7 +77,6 @@ in
};
};
- userdata.groups = [ "seat" ];
security.pam.services.swaylock.text = "auth include login";
hardware.opengl.enable = true;
}
diff --git a/hosts/kay/modules/sftp.nix b/hosts/kay/modules/sftp.nix
index b969652..07b1449 100644
--- a/hosts/kay/modules/sftp.nix
+++ b/hosts/kay/modules/sftp.nix
@@ -2,7 +2,8 @@
let
storage = "/hdd/users";
- pubkeys = config.userdata.pubKeys;
+ user = config.userdata.user;
+ pubKeys = config.users.users.${user}.openssh.authorizedKeys.keys;
in
{
users = {
@@ -15,7 +16,7 @@ in
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIFmA1dyV+o9gfoxlbVG0Y+dn3lVqdFs5fMqfxyNc5/Lr sftp@cez"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDCbgjAfyDNtLNyOS+sfLirYtfEAkGqV54LOwabpWkvf sftp@veu"
- ] ++ pubkeys;
+ ] ++ pubKeys;
};
users."nazer" = {