wip mbp hw config

This commit is contained in:
Ronja Spiegelberg 2025-01-05 17:46:32 +01:00
parent 161d78902e
commit aee35ecfa3
7 changed files with 86 additions and 31 deletions

View file

@ -89,13 +89,29 @@
"url": "https://git.lix.systems/lix-project/nixos-module/archive/2.91.1-1.tar.gz" "url": "https://git.lix.systems/lix-project/nixos-module/archive/2.91.1-1.tar.gz"
} }
}, },
"nixos-hardware": {
"locked": {
"lastModified": 1735388221,
"narHash": "sha256-e5IOgjQf0SZcFCEV/gMGrsI0gCJyqOKShBQU0iiM3Kg=",
"owner": "NixOS",
"repo": "nixos-hardware",
"rev": "7c674c6734f61157e321db595dbfcd8523e04e19",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "master",
"repo": "nixos-hardware",
"type": "github"
}
},
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1735531152, "lastModified": 1735922141,
"narHash": "sha256-As8I+ebItDKtboWgDXYZSIjGlKeqiLBvjxsQHUmAf1Q=", "narHash": "sha256-vk0xwGZSlvZ/596yxOtsk4gxsIx2VemzdjiU8zhjgWw=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "3ffbbdbac0566a0977da3d2657b89cbcfe9a173b", "rev": "d29ab98cd4a70a387b8ceea3e930b3340d41ac5a",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -109,6 +125,7 @@
"inputs": { "inputs": {
"home-manager": "home-manager", "home-manager": "home-manager",
"lix-module": "lix-module", "lix-module": "lix-module",
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs"
} }
}, },

View file

@ -1,6 +1,7 @@
{ {
inputs = { inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.11"; nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.11";
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
home-manager = { home-manager = {
url = "github:nix-community/home-manager/release-24.11"; url = "github:nix-community/home-manager/release-24.11";
@ -19,6 +20,7 @@
nixpkgs, nixpkgs,
home-manager, home-manager,
lix-module, lix-module,
nixos-hardware,
}: }:
{ {
nixosConfigurations = nixosConfigurations =
@ -27,6 +29,7 @@
inherit nixpkgs; inherit nixpkgs;
inherit home-manager; inherit home-manager;
inherit lix-module; inherit lix-module;
inherit nixos-hardware;
common-modules = [ common-modules = [
lix-module.nixosModules.default lix-module.nixosModules.default
./common ./common

View file

@ -2,21 +2,30 @@
nixpkgs, nixpkgs,
common-modules, common-modules,
desktop-modules, desktop-modules,
nixos-hardware,
home-manager,
... ...
}: }:
nixpkgs.lib.nixosSystem { nixpkgs.lib.nixosSystem {
system = "x86_64-linux"; system = "x86_64-linux";
modules = modules = common-modules ++ [
common-modules home-manager.nixosModules.home-manager
++ desktop-modules ../../home
++ [ ../../modules/desktop-environment.nix
nixos-hardware.nixosModules.apple-macbook-pro-14-1
{ allowedUnfreePackages = [ "b43-firmware" ]; }
./hardware.nix ./hardware.nix
../../home/gnome.nix ../../home/gnome.nix
../../users/ronja.nix ../../users/ronja.nix
../../modules/gnome.nix ../../modules/gnome.nix
{ {
networking.hostName = "ona-book"; networking = {
hostName = "ona-book";
networkmanager.enable = true;
};
services.xserver.xkb = { services.xserver.xkb = {
layout = "us"; layout = "us";
options = "eurosign:e,caps:escape"; options = "eurosign:e,caps:escape";

View file

@ -20,8 +20,24 @@
"sd_mod" "sd_mod"
]; ];
initrd.kernelModules = [ ]; initrd.kernelModules = [ ];
kernelModules = [ "kvm-intel" ]; kernelModules = [
"kvm-intel"
"snd_hda_codec_cs8409"
"hci_uart"
"bluetooth"
"btbcm"
];
extraModulePackages = [ ]; extraModulePackages = [ ];
blacklistedKernelModules = [ ];
kernelParams = [];
loader = {
efi.canTouchEfiVariables = true;
systemd-boot = {
enable = true;
editor = false; # do not allow changing kernel parameters
consoleMode = "max";
};
};
}; };
fileSystems = { fileSystems = {
@ -53,5 +69,11 @@
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.enableAllFirmware = true;
nixpkgs.config.allowUnfree = true;
hardware.enableRedistributableFirmware = true;
hardware.facetimehd.enable = true;
}; };
} }

View file

@ -21,7 +21,10 @@ nixpkgs.lib.nixosSystem {
../../modules/podman.nix ../../modules/podman.nix
{ {
networking.hostName = "vinzenz-lpt2"; networking = {
hostName = "vinzenz-lpt2";
networkmanager.enable = true;
};
nix.settings.extra-platforms = [ nix.settings.extra-platforms = [
"aarch64-linux" "aarch64-linux"
"i686-linux" "i686-linux"

View file

@ -20,7 +20,10 @@ nixpkgs.lib.nixosSystem {
../../modules/printing.nix ../../modules/printing.nix
../../modules/podman.nix ../../modules/podman.nix
{ {
networking.hostName = "vinzenz-pc2"; networking = {
hostName = "vinzenz-pc2";
networkmanager.enable = true;
};
nix.settings.extra-platforms = [ nix.settings.extra-platforms = [
"aarch64-linux" "aarch64-linux"
"i686-linux" "i686-linux"

View file

@ -58,8 +58,6 @@
}; };
networking = { networking = {
networkmanager.enable = true;
firewall = { firewall = {
allowedTCPPortRanges = [ allowedTCPPortRanges = [
{ {