2024-02-04 15:31:33 +02:00
|
|
|
{
|
2024-02-04 16:18:47 +02:00
|
|
|
self,
|
|
|
|
lib,
|
2024-02-04 15:31:33 +02:00
|
|
|
pkgs,
|
2024-02-04 22:28:36 +02:00
|
|
|
myData,
|
2024-02-04 22:05:44 +02:00
|
|
|
config,
|
2024-02-04 16:18:47 +02:00
|
|
|
modulesPath,
|
2024-02-04 15:31:33 +02:00
|
|
|
...
|
|
|
|
}: {
|
2024-02-04 16:18:47 +02:00
|
|
|
imports = [
|
|
|
|
"${modulesPath}/profiles/all-hardware.nix"
|
|
|
|
"${modulesPath}/installer/cd-dvd/iso-image.nix"
|
|
|
|
../../modules/profiles/desktop
|
|
|
|
];
|
|
|
|
|
|
|
|
home-manager.useGlobalPkgs = true;
|
2024-02-04 22:05:44 +02:00
|
|
|
home-manager.users.nixos = {pkgs, ...}:
|
2024-02-04 22:23:56 +02:00
|
|
|
import ../../shared/home/default.nix {
|
|
|
|
inherit lib;
|
|
|
|
inherit pkgs;
|
|
|
|
inherit (config.mj) stateVersion;
|
|
|
|
username = "nixos";
|
|
|
|
devTools = true;
|
|
|
|
hmOnly = false;
|
|
|
|
email = "motiejus@jakstys.lt";
|
|
|
|
};
|
2024-02-04 16:18:47 +02:00
|
|
|
|
2024-02-04 15:31:33 +02:00
|
|
|
mj = {
|
2024-02-04 16:18:47 +02:00
|
|
|
stateVersion = "23.11";
|
2024-02-04 15:31:33 +02:00
|
|
|
timeZone = "UTC";
|
2024-02-04 16:18:47 +02:00
|
|
|
desktop = {
|
|
|
|
username = "nixos";
|
|
|
|
configureDM = false;
|
2024-02-04 15:31:33 +02:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2024-02-04 16:18:47 +02:00
|
|
|
isoImage = {
|
2024-02-04 18:16:15 +02:00
|
|
|
isoName = "toolshed-${self.lastModifiedDate}.iso";
|
2024-02-04 16:18:47 +02:00
|
|
|
squashfsCompression = "zstd";
|
|
|
|
appendToMenuLabel = " Toolshed ${self.lastModifiedDate}";
|
|
|
|
makeEfiBootable = true; # EFI booting
|
|
|
|
makeUsbBootable = true; # USB booting
|
2024-02-04 15:31:33 +02:00
|
|
|
};
|
|
|
|
|
2024-02-04 16:18:47 +02:00
|
|
|
boot.kernelPackages = pkgs.zfs.latestCompatibleLinuxPackages;
|
|
|
|
|
|
|
|
swapDevices = [];
|
|
|
|
|
2024-02-04 15:31:33 +02:00
|
|
|
services = {
|
2024-02-04 16:18:47 +02:00
|
|
|
pcscd.enable = true;
|
|
|
|
getty.autologinUser = "nixos";
|
|
|
|
xserver = {
|
2024-02-04 15:31:33 +02:00
|
|
|
enable = true;
|
2024-02-04 16:18:47 +02:00
|
|
|
desktopManager.xfce.enable = true;
|
|
|
|
displayManager = {
|
|
|
|
lightdm.enable = true;
|
|
|
|
autoLogin = {
|
|
|
|
enable = true;
|
|
|
|
user = "nixos";
|
|
|
|
};
|
2024-02-04 15:31:33 +02:00
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2024-02-04 16:18:47 +02:00
|
|
|
programs = {
|
|
|
|
ssh.startAgent = false;
|
|
|
|
gnupg.agent = {
|
|
|
|
enable = true;
|
|
|
|
enableSSHSupport = true;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
users.users = {
|
|
|
|
nixos = {
|
|
|
|
isNormalUser = true;
|
|
|
|
extraGroups = ["wheel" "video"];
|
|
|
|
initialHashedPassword = "";
|
2024-02-04 22:28:36 +02:00
|
|
|
openssh.authorizedKeys.keys = [myData.people_pubkeys.motiejus];
|
2024-02-04 16:18:47 +02:00
|
|
|
};
|
|
|
|
root.initialHashedPassword = "";
|
|
|
|
};
|
|
|
|
|
|
|
|
security = {
|
|
|
|
pam.services.lightdm.text = ''
|
|
|
|
auth sufficient pam_succeed_if.so user ingroup wheel
|
|
|
|
'';
|
|
|
|
sudo = {
|
|
|
|
enable = true;
|
|
|
|
wheelNeedsPassword = false;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2024-02-04 15:31:33 +02:00
|
|
|
networking = {
|
|
|
|
hostName = "vm";
|
2024-02-04 22:28:36 +02:00
|
|
|
domain = "jakstys.lt";
|
2024-02-04 16:18:47 +02:00
|
|
|
firewall.allowedTCPPorts = [22];
|
2024-02-04 15:31:33 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
nix = {
|
|
|
|
extraOptions = ''
|
|
|
|
experimental-features = nix-command flakes
|
2024-02-04 22:28:36 +02:00
|
|
|
trusted-users = nixos
|
2024-02-04 15:31:33 +02:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
}
|