feat: add desktop (ooksdesk) system configuration file

This commit is contained in:
ooks-io 2024-02-11 20:48:51 +13:00
parent b4030c16b9
commit 036fbcfcf2

View file

@ -1,88 +1,22 @@
{ inputs, pkgs, ... }:
{ config, inputs, pkgs, ... }:
{
imports = [
inputs.hardware.nixosModule.common-cpu-intel
inputs.hardware.nixosModule.common-pc-ssd
./hardware-configuration.nix # Hardware configuration generated by nix-generate-config
../common/user/ooks # Add and configure the user "ooks"
../common/base # Default system programs
../common/features/vm.nix # Adds VM support
../common/features/greetd.nix # Adds login-manager greetd
./hardware-configuration.nix
../../profiles
];
activeProfiles = ["base"];
systemModules.user = {
ooks.enable = true;
shell.fish.enable = true;
};
networking = {
hostName = "ooksdesk"; # Define hostname
networkmanager.enable = true; # Networking tool
hostName = "ooksdesk";
};
boot = {
kernelPackages = pkgs.linuxKernel.packages.linux_zen; # Kernel version
supportedFilesystems = ["ntfs"]; # Add ntfs support
};
programs = {
dconf.enable = true; # Low level configuration system
kdeconnect.enable = true; # Adds android connectivity over local network
gnupg.agent = { # Daemon to request and cache passwords for the keychain
enable = true;
enableSSHSupport = true;
};
};
xdg.portal = { # Allows cross-desktop communication
enable = true;
wlr.enable = true; # Adds Wayland support
};
hardware = {
opengl = { # Used for rendering 2D and 3D graphics
enable = true;
driSupport = true;
driSupport32Bit = true;
extraPackages = with pkgs; [nvidia-vaapi-driver]; # Adds nvidia VAAPI driver for hardware-accelerated video decoding
};
nvidia = {
open = true; # Use Nvidia's open source kernel module
modesetting.enable = true; # Enables kernel modesettings
nvidiaSettings = true; # Nvidia's settings GUI
};
};
services = {
dbus = { # Allows communication between applications
enable = true;
packages = [ pkgs.gcr ]; # GNOME cryptographic services, used for managing cryptographic keys
};
xserver.videoDrivers = ["nvidia"]; # Required for Nvidia to work
udisks2 = { # Used to manage mounting of temp storage
enable = true;
mountOnMedia = true; # Auto mounts device to /media
};
};
environment = {
variables = { # Environment variables for nvidia
GBM_BACKEND = "nvidia-drm";
LIBVA_DRIVER_NAME = "nvidia";
__GLX_VENDOR_LIBRARY_NAME = "nvidia";
};
systemPackages = with pkgs; [ # Vulkan packages
vulkan-loader
vulkan-validation-layers
vulkan-tools
];
};
system = {
stateVersion = "22.05";
kernelPackages = pkgs.linuxKernel.packages.linux_zen;
};
}