2023-11-08 22:18:10 +00:00
|
|
|
|
{ config, pkgs, lib, ... }:
|
|
|
|
|
|
|
|
|
|
{
|
|
|
|
|
imports =
|
|
|
|
|
[ # Include the results of the hardware scan.
|
|
|
|
|
./modules/packages.nix
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
# Bootloader.
|
|
|
|
|
boot.loader = {
|
2023-11-10 14:22:36 +00:00
|
|
|
|
timeout = 1;
|
2023-11-08 22:18:10 +00:00
|
|
|
|
systemd-boot.enable = true;
|
|
|
|
|
efi.canTouchEfiVariables = true;
|
|
|
|
|
};
|
|
|
|
|
|
2023-11-10 14:22:36 +00:00
|
|
|
|
boot.plymouth.enable = true;
|
|
|
|
|
# start kernel in quiet output mode
|
2023-11-16 14:18:26 +00:00
|
|
|
|
boot.kernelParams = ["amdgpu.sg_display=0"];
|
2023-11-10 14:22:36 +00:00
|
|
|
|
|
|
|
|
|
# clean temp dir on every boot
|
|
|
|
|
boot.tmp.cleanOnBoot = true;
|
|
|
|
|
|
2023-11-08 22:18:10 +00:00
|
|
|
|
# newest kernel
|
2023-11-26 21:32:14 +00:00
|
|
|
|
boot.kernelPackages = pkgs.linuxPackages_testing;
|
2023-11-16 14:18:26 +00:00
|
|
|
|
# set mainline kernel version
|
|
|
|
|
#boot.kernelPackages = pkgs.linuxKernel.packages.linux_6_5;
|
|
|
|
|
# set specific kernel version
|
2023-11-26 21:32:14 +00:00
|
|
|
|
#boot.kernelPackages = pkgs.linuxPackagesFor (pkgs.linux_6_6.override {
|
|
|
|
|
# argsOverride = rec {
|
|
|
|
|
# src = pkgs.fetchurl {
|
|
|
|
|
# url = "mirror://kernel/linux/kernel/v6.x/linux-${version}.tar.xz";
|
|
|
|
|
# sha256 = "sha256-c9T2rY3WrCpB7VLCkoiYt8PyUZ7V29sRkgIJo2mZt34=";
|
|
|
|
|
# };
|
|
|
|
|
# version = "6.6.2";
|
|
|
|
|
# modDirVersion = "6.6.2";
|
|
|
|
|
# };
|
|
|
|
|
#});
|
2023-11-16 14:18:26 +00:00
|
|
|
|
|
2023-11-08 22:18:10 +00:00
|
|
|
|
|
|
|
|
|
# Enable networking
|
|
|
|
|
networking.networkmanager.enable = true;
|
|
|
|
|
|
|
|
|
|
# Set your time zone.
|
|
|
|
|
time.timeZone = "Europe/Vienna";
|
|
|
|
|
|
|
|
|
|
# Select internationalisation properties.
|
|
|
|
|
i18n.defaultLocale = "en_US.UTF-8";
|
|
|
|
|
|
|
|
|
|
i18n.extraLocaleSettings = {
|
|
|
|
|
LC_ADDRESS = "de_AT.UTF-8";
|
|
|
|
|
LC_IDENTIFICATION = "de_AT.UTF-8";
|
|
|
|
|
LC_MEASUREMENT = "de_AT.UTF-8";
|
|
|
|
|
LC_MONETARY = "de_AT.UTF-8";
|
|
|
|
|
LC_NAME = "de_AT.UTF-8";
|
|
|
|
|
LC_NUMERIC = "de_AT.UTF-8";
|
|
|
|
|
LC_PAPER = "de_AT.UTF-8";
|
|
|
|
|
LC_TELEPHONE = "de_AT.UTF-8";
|
|
|
|
|
LC_TIME = "de_AT.UTF-8";
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
# Enable the X11 windowing system.
|
|
|
|
|
services.xserver.enable = true;
|
|
|
|
|
|
|
|
|
|
# Enable the GNOME Desktop Environment.
|
|
|
|
|
services.xserver.displayManager.gdm.enable = true;
|
|
|
|
|
services.xserver.desktopManager.gnome.enable = true;
|
|
|
|
|
|
|
|
|
|
# Configure keymap in X11
|
|
|
|
|
services.xserver = {
|
|
|
|
|
layout = "at";
|
|
|
|
|
xkbVariant = "";
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
# Enable CUPS to print documents.
|
|
|
|
|
services.printing.enable = true;
|
|
|
|
|
|
|
|
|
|
# Enable sound with pipewire.
|
|
|
|
|
sound.enable = true;
|
|
|
|
|
hardware.pulseaudio.enable = false;
|
|
|
|
|
security.rtkit.enable = true;
|
|
|
|
|
services.pipewire = {
|
|
|
|
|
enable = true;
|
|
|
|
|
alsa.enable = true;
|
|
|
|
|
alsa.support32Bit = true;
|
|
|
|
|
pulse.enable = true;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
# Define a user account. Don't forget to set a password with ‘passwd’.
|
|
|
|
|
users.users.lukas = {
|
|
|
|
|
isNormalUser = true;
|
|
|
|
|
description = "Lukas Heiligenbrunner";
|
|
|
|
|
extraGroups = [ "networkmanager" "wheel" ];
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
# Allow unfree packages
|
|
|
|
|
nixpkgs.config.allowUnfree = true;
|
|
|
|
|
|
|
|
|
|
users.defaultUserShell = pkgs.zsh;
|
|
|
|
|
|
|
|
|
|
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
|
|
|
|
|
|
|
|
|
# automatically delete older generations and keep last 5
|
|
|
|
|
nix.settings.auto-optimise-store = true;
|
|
|
|
|
nix.gc.automatic = true;
|
|
|
|
|
nix.gc.dates = "daily";
|
2023-11-10 14:22:36 +00:00
|
|
|
|
nix.gc.options = "--delete-older-than 3d";
|
|
|
|
|
system.activationScripts.text =
|
|
|
|
|
''
|
|
|
|
|
# keep only last 5 generations
|
|
|
|
|
#nix-env --delete-generations +5 -p /nix/var/nix/profiles/system
|
|
|
|
|
'';
|
2023-11-08 22:18:10 +00:00
|
|
|
|
|
|
|
|
|
# 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. It‘s 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).
|
2023-11-25 12:55:15 +00:00
|
|
|
|
system.stateVersion = "23.11"; # Did you read the comment?
|
2023-11-08 22:18:10 +00:00
|
|
|
|
|
|
|
|
|
}
|