nix-configs/systems/smolboi/configuration.nix

230 lines
5.5 KiB
Nix
Raw Normal View History

2024-05-04 13:21:11 -04:00
{ config, lib, pkgs, sops, ... }:
2024-04-05 22:04:41 -04:00
{
2024-05-11 12:51:25 -04:00
imports = [ # Include the results of the hardware scan.
2024-04-05 22:04:41 -04:00
./hardware-configuration.nix
2024-04-26 14:14:50 -04:00
../../modules/common.nix
2024-04-27 22:10:36 -04:00
../../modules/aarch64-emu.nix
2024-04-26 12:48:13 -04:00
../../modules/smartd.nix
2024-05-31 20:50:40 -04:00
../../modules/plymouth.nix
2024-04-05 22:04:41 -04:00
];
boot = {
loader.systemd-boot.enable = true;
loader.efi.canTouchEfiVariables = true;
binfmt.registrations.appimage = {
wrapInterpreterInShell = false;
interpreter = "${pkgs.appimage-run}/bin/appimage-run";
recognitionType = "magic";
offset = 0;
2024-05-11 12:51:25 -04:00
mask = "\\xff\\xff\\xff\\xff\\x00\\x00\\x00\\x00\\xff\\xff\\xff";
magicOrExtension = "\\x7fELF....AI\\x02";
2024-04-05 22:04:41 -04:00
};
2024-05-04 20:08:41 -04:00
tmp.cleanOnBoot = true;
2024-04-05 22:04:41 -04:00
};
2024-05-04 13:21:11 -04:00
sops.secrets."cdombroski/password" = {
neededForUsers = true;
sopsFile = ../../secrets/smolboi/users.yaml;
};
2024-04-05 22:04:41 -04:00
networking = {
hostName = "smolboi"; # Define your hostname.
2024-05-11 12:51:25 -04:00
networkmanager.enable =
true; # Easiest to use and most distros use this by default.
2024-04-05 22:04:41 -04:00
firewall.allowedTCPPorts = [ 22000 ];
};
nixpkgs.config = {
allowUnfree = true;
2024-05-11 12:51:25 -04:00
permittedInsecurePackages = [ "electron-25.9.0" "nix-2.16.2" ];
2024-04-05 22:04:41 -04:00
packageOverrides = pkgs: {
steam = pkgs.steam.override {
2024-05-11 12:51:25 -04:00
extraPkgs = pkgs:
with pkgs; [
xorg.libXcursor
xorg.libXi
xorg.libXinerama
xorg.libXScrnSaver
libpng
libpulseaudio
libvorbis
stdenv.cc.cc.lib
libkrb5
keyutils
winetricks
];
2024-04-05 22:04:41 -04:00
};
};
};
services = {
2024-07-09 13:06:41 -04:00
ratbagd.enable = true;
2024-05-30 20:39:54 -04:00
displayManager.sddm = {
2024-04-05 22:04:41 -04:00
enable = true;
2024-05-30 20:39:54 -04:00
autoNumlock = true;
wayland.enable = true;
2024-04-05 22:04:41 -04:00
};
2024-05-30 20:39:54 -04:00
desktopManager.plasma6.enable = true;
2024-04-05 22:04:41 -04:00
printing = {
enable = true;
drivers = [ pkgs.gutenprint ];
};
avahi = {
enable = true;
2024-05-30 20:39:54 -04:00
nssmdns4 = true;
nssmdns6 = true;
2024-04-05 22:04:41 -04:00
openFirewall = true;
};
printing.cups-pdf.enable = true;
pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
};
hardware.openrgb.enable = true;
resolved.enable = true;
2024-05-03 16:59:53 -04:00
btrfs.autoScrub = {
enable = true;
fileSystems = [ "/" "/home" ];
};
2024-04-05 22:04:41 -04:00
};
hardware = {
sane = {
enable = true;
extraBackends = [ pkgs.sane-airscan ];
};
bluetooth.enable = true;
};
security = {
2024-05-04 20:08:41 -04:00
sudo.extraConfig = "Defaults lecture = never";
2024-04-05 22:04:41 -04:00
rtkit.enable = true;
};
2024-05-04 13:41:47 -04:00
users.users = {
cdombroski = {
2024-05-31 01:13:03 -04:00
description = "Chris Dombroski";
2024-05-04 13:41:47 -04:00
isNormalUser = true;
extraGroups = [ "wheel" ];
uid = 1000;
hashedPasswordFile = config.sops.secrets."cdombroski/password".path;
2024-05-04 13:21:11 -04:00
};
2024-04-05 22:04:41 -04:00
};
environment = {
systemPackages = with pkgs; [
vim-full # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
libreoffice-qt
firefox
syncthing
chromium
skanlite
htop
kate
cifs-utils
2024-05-04 12:26:22 -04:00
tio
2024-06-01 18:47:07 -04:00
p7zip
rar
2024-07-09 13:04:44 -04:00
piper
2024-04-05 22:04:41 -04:00
];
2024-05-04 20:08:41 -04:00
persistence."/persist" = {
hideMounts = true;
directories = [
"/etc/NetworkManager/system-connections"
"/var/lib/bluetooth"
"/var/lib/nixos"
"/var/log"
"/var/lib/systemd"
"/tmp"
"/var/lib/cups"
];
files = [
"/etc/machine-id"
"/var/lib/NetworkManager/secret_key"
"/etc/adjtime"
"/etc/ssh/ssh_host_rsa_key"
"/etc/ssh/ssh_host_rsa_key.pub"
"/etc/ssh/ssh_host_ed25519_key"
"/etc/ssh/ssh_host_ed25519_key.pub"
];
};
2024-04-05 22:04:41 -04:00
};
programs = {
gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
steam = {
enable = true;
remotePlay.openFirewall = true;
gamescopeSession.enable = true;
};
2024-05-11 12:51:25 -04:00
firefox.nativeMessagingHosts.packages = with pkgs; [
keepassxc
libsForQt5.plasma-browser-integration
];
2024-04-05 22:04:41 -04:00
gamemode = {
enable = true;
settings = {
general = {
reaper_freq = 5;
desiredgov = "performance";
softrealtime = "auto";
};
gpu = {
apply_gpu_optimisations = "accept-responsibility";
gpu_device = 0;
amd_performance_level = "high";
};
};
};
gamescope.enable = true;
};
zramSwap = {
enable = true;
2024-05-11 12:51:25 -04:00
writebackDevice =
"/dev/disk/by-partuuid/e8f5eaf8-46ca-40de-854a-f6dfe964b92d";
2024-04-05 22:04:41 -04:00
};
fileSystems = {
2024-05-11 12:51:25 -04:00
"/persist".options =
[ "compress=lzo" "autodefrag" "discard=async" "defaults" ];
"/nix".options =
[ "compress=lzo" "autodefrag" "discard=async" "noatime" "defaults" ];
"/steam-library".options =
[ "compress=lzo" "autodefrag" "discard=async" "defaults" ];
"/home".options =
[ "compress=lzo" "autodefrag" "discard=async" "defaults" ];
2024-04-05 22:04:41 -04:00
};
2024-05-27 21:02:31 -04:00
stylix = {
2024-05-30 20:39:54 -04:00
image =
2024-05-31 00:08:26 -04:00
"${pkgs.kdePackages.breeze}/share/wallpapers/Next/contents/images_dark/2560x1440.png";
2024-05-31 21:59:03 -04:00
base16Scheme = "${pkgs.base16-schemes}/share/themes/solarflare.yaml";
2024-05-27 21:02:31 -04:00
fonts = {
serif = {
package = pkgs.noto-fonts;
name = "Noto Serif";
};
sansSerif = {
package = pkgs.noto-fonts;
name = "Noto Sans";
};
monospace = {
package = pkgs.jetbrains-mono;
name = "JetBrains Mono Regular";
};
};
cursor = {
2024-05-31 20:04:28 -04:00
package = pkgs.kdePackages.breeze;
2024-05-27 21:02:31 -04:00
name = "breeze_cursors";
size = 24;
};
};
2024-04-05 22:04:41 -04:00
system.stateVersion = "23.11"; # Did you read the comment?
}