diff options
-rwxr-xr-x | machines/adax/cc.nix | 15 | ||||
-rwxr-xr-x | machines/adax/configuration.nix | 16 | ||||
-rwxr-xr-x | machines/adax/default.nix | 6 | ||||
-rwxr-xr-x | machines/adax/hardware-configuration.nix | 38 | ||||
-rwxr-xr-x | machines/hp-compaq/configuration.nix | 16 | ||||
-rwxr-xr-x | machines/hp-compaq/default.nix | 4 | ||||
-rwxr-xr-x | machines/hp-compaq/hardware-configuration.nix | 7 | ||||
-rwxr-xr-x | modules/audio.nix | 9 | ||||
-rwxr-xr-x | modules/larbs.nix | 5 | ||||
-rwxr-xr-x | users/pn.nix | 2 |
10 files changed, 102 insertions, 16 deletions
diff --git a/machines/adax/cc.nix b/machines/adax/cc.nix new file mode 100755 index 0000000..96b12d2 --- /dev/null +++ b/machines/adax/cc.nix @@ -0,0 +1,15 @@ +# Edit this configuration file to define what should be installed on +# your system. Help is available in the configuration.nix(5) man page +# and in the NixOS manual (accessible by running ‘nixos-help’). + +{ config, pkgs, ... }: + +{ + imports = + [ # Include the results of the hardware scan. + ./hardware-configuration.nix + ./dots/machines/hp-compaq/configuration.nix + ]; + + +} diff --git a/machines/adax/configuration.nix b/machines/adax/configuration.nix new file mode 100755 index 0000000..57b80d6 --- /dev/null +++ b/machines/adax/configuration.nix @@ -0,0 +1,16 @@ +{ config, pkgs, ... }: + +{ + + imports = [ + ../base.nix + ../pl.nix + ../../modules/larbs.nix + ]; + + networking.hostName = "adax"; + + environment.systemPackages = with pkgs; [ + ]; + +} diff --git a/machines/adax/default.nix b/machines/adax/default.nix new file mode 100755 index 0000000..246ffea --- /dev/null +++ b/machines/adax/default.nix @@ -0,0 +1,6 @@ +{ + imports = [ + ./configuration.nix + ./hardware-configuration.nix + ]; +} diff --git a/machines/adax/hardware-configuration.nix b/machines/adax/hardware-configuration.nix new file mode 100755 index 0000000..99b9002 --- /dev/null +++ b/machines/adax/hardware-configuration.nix @@ -0,0 +1,38 @@ +# Do not modify this file! It was generated by ‘nixos-generate-config’ +# and may be overwritten by future invocations. Please make changes +# to /etc/nixos/configuration.nix instead. +{ config, lib, pkgs, ... }: + +{ + imports = + [ <nixpkgs/nixos/modules/installer/scan/not-detected.nix> + ]; + + boot.initrd.availableKernelModules = [ "uhci_hcd" "ehci_pci" "ata_piix" "usbhid" "usb_storage" "floppy" "sd_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ "kvm-intel" ]; + boot.extraModulePackages = [ ]; + + boot.loader.grub.enable = true; + boot.loader.grub.version = 2; + boot.loader.grub.device = "/dev/sdc"; # or "nodev" for efi only + + networking.useDHCP = false; + networking.interfaces.enp3s0.useDHCP = true; + + fileSystems."/" = + { device = "/dev/disk/by-uuid/6b9e05c9-827e-4a34-bb35-f2a3da149f44"; + fsType = "ext4"; + }; + + fileSystems."/boot" = + { device = "/dev/disk/by-uuid/7F96-4F40"; + fsType = "vfat"; + }; + + swapDevices = + [ { device = "/dev/disk/by-uuid/cda58eb8-fc1e-4bea-9dca-b119a1da2267"; } + ]; + + nix.maxJobs = lib.mkDefault 2; +} diff --git a/machines/hp-compaq/configuration.nix b/machines/hp-compaq/configuration.nix index 958088c..cc61647 100755 --- a/machines/hp-compaq/configuration.nix +++ b/machines/hp-compaq/configuration.nix @@ -1,22 +1,16 @@ { config, pkgs, ... }: { - imports = - [ # Include the results of the hardware scan. - ./hardware-configuration.nix - ]; - boot.loader.grub.enable = true; - boot.loader.grub.version = 2; - boot.loader.grub.device = "/dev/sda"; # or "nodev" for efi only + imports = [ + ../base.nix + ../pl.nix + ../../modules/larbs.nix + ]; networking.hostName = "hp-compaq"; - networking.useDHCP = false; - networking.interfaces.enp2s0.useDHCP = true; - environment.systemPackages = with pkgs; [ ]; - } diff --git a/machines/hp-compaq/default.nix b/machines/hp-compaq/default.nix index 2b96276..246ffea 100755 --- a/machines/hp-compaq/default.nix +++ b/machines/hp-compaq/default.nix @@ -2,9 +2,5 @@ imports = [ ./configuration.nix ./hardware-configuration.nix - - ../base.nix - ../pl.nix - ../../modules/larbs.nix ]; } diff --git a/machines/hp-compaq/hardware-configuration.nix b/machines/hp-compaq/hardware-configuration.nix index a2f8180..6971c39 100755 --- a/machines/hp-compaq/hardware-configuration.nix +++ b/machines/hp-compaq/hardware-configuration.nix @@ -13,6 +13,13 @@ boot.kernelModules = [ ]; boot.extraModulePackages = [ ]; + boot.loader.grub.enable = true; + boot.loader.grub.version = 2; + boot.loader.grub.device = "/dev/sda"; # or "nodev" for efi only + + networking.useDHCP = false; + networking.interfaces.enp2s0.useDHCP = true; + fileSystems."/" = { device = "/dev/disk/by-uuid/ad2775d5-5890-493e-b709-60c1f7f3c63b"; fsType = "ext4"; diff --git a/modules/audio.nix b/modules/audio.nix new file mode 100755 index 0000000..2563c21 --- /dev/null +++ b/modules/audio.nix @@ -0,0 +1,9 @@ +{ pkgs, ... }: +{ + hardware.pulseaudio.enable = true; + + environment.systemPackages = with pkgs; [ + pulsemixer + pamixer + ]; +} diff --git a/modules/larbs.nix b/modules/larbs.nix index 89c04c0..a116034 100755 --- a/modules/larbs.nix +++ b/modules/larbs.nix @@ -3,6 +3,10 @@ let pnvim = import ../pkgs/nvim.nix pkgs; in { + imports = [ + ./audio.nix + ]; + environment.systemPackages = with pkgs.nur.repos.pn; [ pnvim larbs-mail @@ -16,6 +20,7 @@ in ]; services.xserver = { + enable = true; displayManager.startx.enable = true; libinput.enable = true; }; diff --git a/users/pn.nix b/users/pn.nix index 8789721..3a74358 100755 --- a/users/pn.nix +++ b/users/pn.nix @@ -3,7 +3,7 @@ { users.users.pn = { isNormalUser = true; - extraGroups = [ "wheel" ]; + extraGroups = [ "wheel" "audio" ]; }; ## Although it's less secure I tend not to have sensitive data on my machines |