nixos/hosts/helix-texta/default.nix

178 lines
5.2 KiB
Nix
Raw Normal View History

{
pkgs,
inputs,
...
}: {
imports = [
inputs.nixos-hardware.nixosModules.common-cpu-intel
inputs.nixos-hardware.nixosModules.common-gpu-nvidia
inputs.nixos-hardware.nixosModules.common-pc-laptop
inputs.nixos-hardware.nixosModules.common-pc-laptop-ssd
inputs.nixos-hardware.nixosModules.common-pc-laptop-acpi_call
inputs.self.nixosModules.homeManagerConfig
inputs.custom-udev-rules.nixosModule
2024-01-15 15:59:54 +01:00
../../hardware/thinkpad-p1-gen3.nix
../../modules/light-actkbd.nix
./topology.nix
];
config = {
boot = {
# Use the systemd-boot EFI boot loader.
loader = {
systemd-boot.enable = true;
efi.canTouchEfiVariables = true;
};
2021-05-28 00:15:51 +02:00
};
2021-05-19 23:08:18 +02:00
networking = {
hostName = "helix-texta";
networkmanager.enable = true;
};
nixpkgs.overlays = [
inputs.nixpkgs-wayland.overlay
];
2022-12-01 18:08:49 +01:00
system.fsPackages = [pkgs.sshfs];
2021-06-05 12:07:55 +02:00
settings.minimalGnome.enable = true;
settings.batteryStuff.enable = true;
# Pipewire for my wayland
security.rtkit.enable = true;
services.pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
jack.enable = true;
# config.pipewire-pulse."stream.properties" = {
# "channelmix.upmix" = true;
# "channelmix.lfe-cutoff" = 150;
# };
# config.pipewire = {"default.clock.allowed-rates" = [48000 44100];};
# media-session.config.media-session = lib.recursiveUpdate options.services.pipewire.media-session.config.media-session.default {
# "session.modules".default = options.services.pipewire.media-session.config.media-session.default."session.modules".default ++ ["default-profile"];
# };
# media-session.config.alsa-monitor = {
# rules = [
# {
# matches = [
# {
# "node.name" = "alsa_output.usb-Focusrite_Scarlett_Solo_USB_Y7ENM550A6399B-00.pro-output-0";
# }
# ];
# actions = {
# update-props = {
# #"audio.rate" = 96000;
# "api.alsa.headroom" = 1024;
# };
# };
# }
# ];
# };
2021-06-05 16:01:32 +02:00
};
xdg.portal = {
2021-07-09 10:46:19 +02:00
enable = true;
config.common.default = "*";
extraPortals = with pkgs; [xdg-desktop-portal-gtk];
2021-07-09 10:46:19 +02:00
};
2021-05-28 00:15:51 +02:00
services.udev.customRules = [
# Rename the Scarlett Solo using udev
{
name = "85-scarlett-solo";
rules = ''
SUBSYSTEM=="usb", ENV{ID_MODEL_ID}=="8211", ENV{ID_VENDOR_ID}=="1235", TAG+="systemd", SYMLINK+="scarlett_solo"
'';
}
{
name = "85-yubikey";
rules = ''
SUBSYSTEM=="usb", ENV{ID_MODEL_ID}=="0407", ENV{ID_VENDOR_ID}=="1050", TAG+="systemd", SYMLINK+="yubikey"
'';
}
];
security.pam = {
yubico = {
control = "sufficient";
mode = "challenge-response";
debug = false;
};
# TODO: Update once my PR lands
services.login.yubicoAuth = true;
};
users.mutableUsers = false;
users.custom.malte.enable = true;
# Use some fonts
fonts = {
enableDefaultPackages = true;
packages = with pkgs; [hack-nerdfont noto-fonts noto-fonts-cjk joypixels];
fontconfig = {
enable = true;
defaultFonts.monospace = ["Hack Nerd Font Mono"];
};
};
2021-05-19 23:08:18 +02:00
# Configure GPG with SSH support and enable the yubikey
programs.gnupg.agent = {
2021-07-04 12:20:47 +02:00
enable = true;
enableSSHSupport = true;
chore: update • Updated input 'devshell': 'github:numtide/devshell/ea8db557d3b438d93bc3937fce098c15b283f0e0' (2024-01-15) → 'github:numtide/devshell/2d45b54ca4a183f2fdcf4b19c895b64fbf620ee8' (2024-03-22) • Updated input 'flake-parts': 'github:hercules-ci/flake-parts/07f6395285469419cf9d078f59b5b49993198c00' (2024-01-11) → 'github:hercules-ci/flake-parts/f7b3c975cf067e56e7cda6cb098ebe3fb4d74ca2' (2024-03-01) • Updated input 'flake-parts/nixpkgs-lib': 'github:NixOS/nixpkgs/b0d36bd0a420ecee3bc916c91886caca87c894e9?dir=lib' (2023-12-30) → 'github:NixOS/nixpkgs/1536926ef5621b09bba54035ae2bb6d806d72ac8?dir=lib' (2024-02-29) • Updated input 'home-manager': 'github:nix-community/home-manager/846200eb574faa2af808ed02e653c2b8ed51fd71' (2024-01-14) → 'github:nix-community/home-manager/1c2c5e4cabba4c43504ef0f8cc3f3dfa284e2dbb' (2024-03-22) • Updated input 'hydra': 'github:NixOS/hydra/02e453fc8c39751843220eaecdeaf7d539b7e765' (2023-12-24) → 'github:NixOS/hydra/8f56209bd6f3b9ec53d50a23812a800dee7a1969' (2024-03-08) • Updated input 'hydra/nix': 'github:NixOS/nix/2c4bb93ba5a97e7078896ebc36385ce172960e4e' (2024-01-25) → 'github:NixOS/nix/8f42912c80c0a03f62f6a3d28a3af05a9762565d' (2024-01-30) • Added input 'hydra/nix/libgit2': 'github:libgit2/libgit2/45fd9ed7ae1a9b74b957ef4f337bc3c8b3df01b5' (2023-10-18) • Removed input 'hydra/nix/lowdown-src' • Updated input 'hydra/nixpkgs': 'github:NixOS/nixpkgs/e9f06adb793d1cca5384907b3b8a4071d5d7cb19' (2023-12-03) → 'github:NixOS/nixpkgs/a1982c92d8980a0114372973cbdfe0a307f1bdea' (2024-01-12) • Added input 'hydra/nixpkgs-for-fileset': 'github:NixOS/nixpkgs/a77ab169a83a4175169d78684ddd2e54486ac651' (2024-01-24) • Updated input 'hyprland': 'github:hyprwm/Hyprland/f14c5ea5c56858260c1133d8003fc5961ace373d' (2024-01-15) → 'github:hyprwm/Hyprland/86dc46ffea2fa72abe1228c1fad1b42d1507e45d' (2024-03-24) • Added input 'hyprland/hyprcursor': 'github:hyprwm/hyprcursor/6a92473237f430399a417e1c2da9d7fcd4970086' (2024-03-21) • Added input 'hyprland/hyprcursor/hyprlang': 'github:hyprwm/hyprlang/a685493fdbeec01ca8ccdf1f3655c044a8ce2fe2' (2024-03-08) • Added input 'hyprland/hyprcursor/hyprlang/nixpkgs': follows 'hyprland/hyprcursor/nixpkgs' • Added input 'hyprland/hyprcursor/hyprlang/systems': 'github:nix-systems/default-linux/31732fcf5e8fea42e59c2488ad31a0e651500f68' (2023-07-14) • Added input 'hyprland/hyprcursor/nixpkgs': follows 'hyprland/nixpkgs' • Added input 'hyprland/hyprcursor/systems': follows 'hyprland/systems' • Added input 'hyprland/hyprlang': 'github:hyprwm/hyprlang/a2f39421144d42541c057be235154ce21b76c0f6' (2024-03-20) • Added input 'hyprland/hyprlang/nixpkgs': follows 'hyprland/nixpkgs' • Added input 'hyprland/hyprlang/systems': follows 'hyprland/systems' • Updated input 'hyprland/wlroots': 'gitlab:wlroots/wlroots/f81c3d93cd6f61b20ae784297679283438def8df' (2023-12-30) → 'gitlab:wlroots/wlroots/50eae512d9cecbf0b3b1898bb1f0b40fa05fe19b' (2024-03-09) • Updated input 'hyprland/xdph': 'github:hyprwm/xdg-desktop-portal-hyprland/6a5de92769d5b7038134044053f90e7458f6a197' (2024-01-07) → 'github:hyprwm/xdg-desktop-portal-hyprland/2d2fb547178ec025da643db57d40a971507b82fe' (2024-03-01) • Updated input 'hyprland/xdph/hyprlang': 'github:hyprwm/hyprlang/6624f2bb66d4d27975766e81f77174adbe58ec97' (2024-01-03) → follows 'hyprland/hyprlang' • Removed input 'hyprland/xdph/hyprlang/nixpkgs' • Updated input 'hyprland-contrib': 'github:hyprwm/contrib/ff256907e67888cbcb6db918f6591e5b1e89db16' (2024-01-15) → 'github:hyprwm/contrib/536f00c5895015da1e7aa85bbee9aa6dcd149e69' (2024-03-21) • Updated input 'jovian-nixos': 'github:Jovian-Experiments/Jovian-NixOS/ab807f9740c533070e8b68b0d86034d4a293b5f1' (2024-01-14) → 'github:Jovian-Experiments/Jovian-NixOS/1171169117f63f1de9ef2ea36efd8dcf377c6d5a' (2024-03-23) • Updated input 'nix-colors': 'github:Misterio77/nix-colors/37227f274b34a3b51649166deb94ce7fec2c6a4c' (2023-09-22) → 'github:Misterio77/nix-colors/b01f024090d2c4fc3152cd0cf12027a7b8453ba1' (2024-02-13) • Updated input 'nix-colors/base16-schemes': 'github:tinted-theming/base16-schemes/d95123ca6377cd849cfdce92c0a24406b0c6a789' (2023-07-16) → 'github:tinted-theming/base16-schemes/a9112eaae86d9dd8ee6bb9445b664fba2f94037a' (2023-10-01) • Updated input 'nix-colors/nixpkgs-lib': 'github:nix-community/nixpkgs.lib/819180647f428a3826bfc917a54449da1e532ce0' (2023-09-17) → 'github:nix-community/nixpkgs.lib/e1e11fdbb01113d85c7f41cada9d2847660e3902' (2023-10-22) • Updated input 'nixos-hardware': 'github:NixOS/nixos-hardware/bee2202bec57e521e3bd8acd526884b9767d7fa0' (2024-01-15) → 'github:NixOS/nixos-hardware/7559df1e4af972d5f1de87975b5ef6a8d7559db2' (2024-03-24) • Updated input 'nixpkgs': 'github:NixOS/nixpkgs/97b17f32362e475016f942bbdfda4a4a72a8a652' (2024-01-29) → 'github:NixOS/nixpkgs/44d0940ea560dee511026a53f0e2e2cde489b4d4' (2024-03-23) • Updated input 'nixpkgs-wayland': 'github:nix-community/nixpkgs-wayland/25ea5dd63dab3d63f679071a30994ae711c906ba' (2024-01-15) → 'github:nix-community/nixpkgs-wayland/59f7ad2c27737a7ea7ad16a48c95631f159ef822' (2024-03-24) • Updated input 'nixpkgs-wayland/lib-aggregate': 'github:nix-community/lib-aggregate/b170b6a80de0a6df07d73594290dcd6d26ef7bbb' (2024-01-15) → 'github:nix-community/lib-aggregate/120535dff702c551ec76a125a181d90131407264' (2024-03-24) • Updated input 'nixpkgs-wayland/lib-aggregate/flake-utils': 'github:numtide/flake-utils/1ef2e671c3b0c19053962c07dbda38332dcebf26' (2024-01-15) → 'github:numtide/flake-utils/b1d9ab70662946ef0850d488da1c9019f3a9752a' (2024-03-11) • Updated input 'nixpkgs-wayland/lib-aggregate/nixpkgs-lib': 'github:nix-community/nixpkgs.lib/da839f74dc77c9826fa333b1bc2c8258fd6ffcbe' (2024-01-14) → 'github:nix-community/nixpkgs.lib/b2a1eeef8c185f6bd27432b053ff09d773244cbc' (2024-03-24) • Updated input 'nixpkgs-wayland/nixpkgs': 'github:nixos/nixpkgs/9b19f5e77dd906cb52dade0b7bd280339d2a1f3d' (2024-01-13) → 'github:nixos/nixpkgs/44d0940ea560dee511026a53f0e2e2cde489b4d4' (2024-03-23) • Updated input 'pre-commit-hooks-nix': 'github:cachix/pre-commit-hooks.nix/ffa9a5b90b0acfaa03b1533b83eaf5dead819a05' (2024-01-14) → 'github:cachix/pre-commit-hooks.nix/e611897ddfdde3ed3eaac4758635d7177ff78673' (2024-03-20) • Updated input 'pre-commit-hooks-nix/flake-utils': 'github:numtide/flake-utils/4022d587cbbfd70fe950c1e2083a02621806a725' (2023-12-04) → 'github:numtide/flake-utils/b1d9ab70662946ef0850d488da1c9019f3a9752a' (2024-03-11) • Updated input 'pre-commit-hooks-nix/gitignore': 'github:hercules-ci/gitignore.nix/43e1aa1308018f37118e34d3a9cb4f5e75dc11d5' (2023-12-29) → 'github:hercules-ci/gitignore.nix/637db329424fd7e46cf4185293b9cc8c88c95394' (2024-02-28) • Updated input 'pre-commit-hooks-nix/nixpkgs': 'github:NixOS/nixpkgs/eabe8d3eface69f5bb16c18f8662a702f50c20d5' (2024-01-09) → 'github:NixOS/nixpkgs/e367f7a1fb93137af22a3908f00b9a35e2d286a7' (2024-03-18) • Updated input 'pre-commit-hooks-nix/nixpkgs-stable': 'github:NixOS/nixpkgs/3dc440faeee9e889fe2d1b4d25ad0f430d449356' (2024-01-10) → 'github:NixOS/nixpkgs/614b4613980a522ba49f0d194531beddbb7220d3' (2024-03-17) • Updated input 'qmk-udev-rules': 'github:qmk/qmk_firmware/dcc47ea31b3f4ef097a2fc677bdbb9b2560d905a' (2024-01-14) → 'github:qmk/qmk_firmware/4afbade6d122183920a888c8e6e1de4581e657fa' (2024-03-22) • Updated input 'sops-nix': 'github:Mic92/sops-nix/70dd0d521f7849338e487a219c1a07c429a66d77' (2024-01-14) → 'github:Mic92/sops-nix/405987a66cce9a4a82f321f11b205982a7127c88' (2024-03-24) • Updated input 'sops-nix/nixpkgs-stable': 'github:NixOS/nixpkgs/a1982c92d8980a0114372973cbdfe0a307f1bdea' (2024-01-12) → 'github:NixOS/nixpkgs/ac6bdf6181666ebb4f90dd20f31e2fa66ede6b68' (2024-03-23) • Updated input 'treefmt-nix': 'github:numtide/treefmt-nix/04f25d7bec9fb29d2c3bacaa48a3304840000d36' (2024-01-07) → 'github:numtide/treefmt-nix/7ee5aaac63c30d3c97a8c56efe89f3b2aa9ae564' (2024-03-18) • Updated input 'treefmt-nix/nixpkgs': 'github:nixos/nixpkgs/6500b4580c2a1f3d0f980d32d285739d8e156d92' (2023-09-25) → 'github:nixos/nixpkgs/0e74ca98a74bc7270d28838369593635a5db3260' (2024-02-21)
2024-03-24 14:16:25 +01:00
pinentryPackage = pkgs.pinentry-qt;
2021-07-04 12:20:47 +02:00
};
# TODO: This defaults to true, why does it not work with virtualisation.containers.enable?
boot.enableContainers = false;
virtualisation = {
podman = {
enable = true;
# Create a `docker` alias for podman, to use it as a drop-in replacement
dockerCompat = true;
dockerSocket.enable = true;
defaultNetwork.settings.dns_enabled = true;
};
};
programs.steam = {
enable = true;
remotePlay.openFirewall = true;
};
nixpkgs.config.packageOverrides = pkgs: {
steam = pkgs.steam.override {extraPkgs = pkgs: [pkgs.openssl];};
};
2021-05-28 00:15:51 +02:00
services.udev.packages = with pkgs; [yubikey-personalization chrysalis];
environment.systemPackages = with pkgs; [
thunderbolt
qt5.qtwayland
chrysalis
];
# TODO: Remove when firefox' RDD is fixed (allows libva)
environment.variables."MOZ_DISABLE_RDD_SANDBOX" = "1";
services.fwupd.enable = true;
services.devmon.enable = true;
2024-01-15 15:59:54 +01:00
sops.defaultSopsFile = ../../secrets/hosts/helix-texta/secrets.yaml;
sops.age.sshKeyPaths = ["/etc/ssh/ssh_host_ed25519_key"];
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "20.09"; # Did you read the comment?
};
2021-05-19 23:08:18 +02:00
}