zaneyos/workstation/configuration.nix
2024-01-12 01:07:42 -06:00

156 lines
4.0 KiB
Nix
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 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).
{ inputs, config, pkgs, username, hostname, ... }:
{
imports =
[ # Include the results of the hardware scan.
./hardware-configuration.nix
];
# Bootloader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
boot.kernelModules = [ "v4l2loopback" ];
boot.extraModulePackages = [ config.boot.kernelPackages.v4l2loopback ];
networking.hostName = ${hostname}; # Define your hostname.
# Enable networking
networking.networkmanager.enable = true;
# Set your time zone.
time.timeZone = "America/Chicago";
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8";
LC_MONETARY = "en_US.UTF-8";
LC_NAME = "en_US.UTF-8";
LC_NUMERIC = "en_US.UTF-8";
LC_PAPER = "en_US.UTF-8";
LC_TELEPHONE = "en_US.UTF-8";
LC_TIME = "en_US.UTF-8";
};
# Define a user account. Don't forget to set a password with passwd.
users.users.${username} = {
homeMode = "755";
isNormalUser = true;
description = "Tyler Kelley";
extraGroups = [ "networkmanager" "wheel" ];
packages = with pkgs; [];
};
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
vim wget curl
];
fonts.packages = with pkgs; [
(nerdfonts.override { fonts = [ "JetBrainsMono" ]; })
];
# Steam Configuration
programs.steam = {
enable = true;
remotePlay.openFirewall = true;
dedicatedServer.openFirewall = true;
};
# OpenGL
hardware.opengl = {
enable = true;
driSupport = true;
driSupport32Bit = true;
};
programs.hyprland = {
enable = true;
package = inputs.hyprland.packages.${pkgs.system}.hyprland;
};
# Some programs need SUID wrappers, can be configured further or are
# started in user sessions.
programs.mtr.enable = true;
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
# List services that you want to enable:
services.openssh.enable = true;
services.fstrim.enable = true;
services.xserver = {
enable = true;
layout = "us";
xkbVariant = "";
libinput.enable = true;
videoDrivers = [ "amdgpu" ];
displayManager.gdm = {
enable = true;
wayland = true;
};
};
services.pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
jack.enable = true;
};
hardware.pulseaudio.enable = false;
sound.enable = true;
security.rtkit.enable = true;
programs.thunar.enable = true;
services.gvfs.enable = true;
services.tumbler.enable = true;
system.stateVersion = "23.11";
nix = {
settings.auto-optimise-store = true;
gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 7d";
};
};
# Set Environment Variables
environment.variables={
NIXOS_OZONE_WL = "1";
PATH = [
"\${HOME}/.local/bin"
"\${HOME}/.cargo/bin"
"\$/usr/local/bin"
];
NIXPKGS_ALLOW_UNFREE = "1";
SCRIPTDIR = "\${HOME}/.local/share/scriptdeps";
STARSHIP_CONFIG = "\${HOME}/.config/starship/starship.toml";
XDG_CURRENT_DESKTOP = "Hyprland";
XDG_SESSION_TYPE = "wayland";
XDG_SESSION_DESKTOP = "Hyprland";
GDK_BACKEND = "wayland";
CLUTTER_BACKEND = "wayland";
SDL_VIDEODRIVER = "x11";
XCURSOR_SIZE = "24";
XCURSOR_THEME = "Bibata-Modern-Ice";
QT_QPA_PLATFORM = "wayland";
QT_QPA_PLATFORMTHEME = "qt5ct";
QT_WAYLAND_DISABLE_WINDOWDECORATION = "1";
QT_AUTO_SCREEN_SCALE_FACTOR = "1";
MOZ_ENABLE_WAYLAND = "1";
};
nix.settings.experimental-features = [ "nix-command" "flakes" ];
}