this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

init nixos commit

Cameron Taylor ca2eb92b

+261
+222
configuration.nix
··· 1 + # Edit this configuration file to define what should be installed on 2 + # your system. Help is available in the configuration.nix(5) man page 3 + # and in the NixOS manual (accessible by running ‘nixos-help’). 4 + 5 + { config, pkgs, ... }: 6 + 7 + { 8 + imports = 9 + [ # Include the results of the hardware scan. 10 + ./hardware-configuration.nix 11 + ]; 12 + 13 + # Bootloader. 14 + # boot.loader.systemd-boot.enable = true; 15 + boot.loader.grub.enable = true; 16 + boot.loader.grub.devices = [ "nodev" ]; 17 + boot.loader.grub.efiSupport = true; 18 + # boot.loader.efi.canTouchEfiVariables = true; 19 + boot.loader.efi.efiSysMountPoint = "/boot"; 20 + boot.loader.grub.efiInstallAsRemovable = true; 21 + boot.loader.grub.extraEntries = '' 22 + 23 + menuentry "Windows" { 24 + search --fs-uuid --no-floppy --set=root D6E4-28CA 25 + chainloader (''${root})/EFI/Microsoft/Boot/bootmgfw.efi 26 + } 27 + 28 + ''; 29 + 30 + networking.hostName = "nixos"; # Define your hostname. 31 + # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. 32 + 33 + # Configure network proxy if necessary 34 + # networking.proxy.default = "http://user:password@proxy:port/"; 35 + # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain"; 36 + 37 + # Enable networking 38 + networking.networkmanager.enable = true; 39 + 40 + # Set your time zone. 41 + time.timeZone = "America/Toronto"; 42 + 43 + # Select internationalisation properties. 44 + i18n.defaultLocale = "en_CA.UTF-8"; 45 + 46 + # Enable the X11 windowing system. 47 + services.xserver.enable = true; 48 + 49 + # Enable the GNOME Desktop Environment. 50 + services.xserver.displayManager.gdm.enable = true; 51 + services.xserver.desktopManager.gnome.enable = true; 52 + 53 + # Configure keymap in X11 54 + services.xserver = { 55 + xkb.layout = "us"; 56 + xkb.variant = ""; 57 + }; 58 + 59 + # Enable CUPS to print documents. 60 + # services.printing.enable = true; 61 + 62 + # Enable sound with pipewire. 63 + hardware.pulseaudio.enable = false; 64 + security.rtkit.enable = true; 65 + services.pipewire = { 66 + enable = true; 67 + alsa.enable = true; 68 + alsa.support32Bit = true; 69 + pulse.enable = true; 70 + # If you want to use JACK applications, uncomment this 71 + #jack.enable = true; 72 + 73 + # use the example session manager (no others are packaged yet so this is enabled by default, 74 + # no need to redefine it in your config for now) 75 + #media-session.enable = true; 76 + }; 77 + 78 + # Enable touchpad support (enabled default in most desktopManager). 79 + # services.xserver.libinput.enable = true; 80 + 81 + # Define a user account. Don't forget to set a password with ‘passwd’. 82 + users.users.mofin = { 83 + isNormalUser = true; 84 + description = "Cameron"; 85 + extraGroups = [ "networkmanager" "wheel" ]; 86 + packages = with pkgs; [ 87 + # thunderbird 88 + ]; 89 + }; 90 + 91 + # Enable automatic login for the user. 92 + services.displayManager.autoLogin.enable = true; 93 + services.displayManager.autoLogin.user = "mofin"; 94 + 95 + # Workaround for GNOME autologin: https://github.com/NixOS/nixpkgs/issues/103746#issuecomment-945091229 96 + systemd.services."getty@tty1".enable = false; 97 + systemd.services."autovt@tty1".enable = false; 98 + 99 + # Install firefox. 100 + programs.firefox.enable = true; 101 + 102 + # Allow unfree packages 103 + nixpkgs.config.allowUnfree = true; 104 + 105 + 106 + # List packages installed in system profile. To search, run: 107 + # $ nix search wget 108 + environment.systemPackages = with pkgs; [ 109 + vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default. 110 + wget 111 + vscode 112 + git 113 + networkmanager 114 + git-credential-oauth 115 + pass 116 + haxe 117 + neko 118 + blackbox-terminal 119 + nix-search-cli 120 + spotify 121 + lshw 122 + ]; 123 + 124 + 125 + services.pcscd.enable = true; 126 + programs.gnupg.agent = { 127 + enable = true; 128 + pinentryPackage = pkgs.pinentry-curses; 129 + enableSSHSupport = true; 130 + }; 131 + 132 + # Graphics / GPU stuff 133 + services.xserver.videoDrivers = ["nvidia"]; 134 + 135 + 136 + hardware.opengl = { 137 + enable = true; 138 + extraPackages = with pkgs; [ libva nvidia-vaapi-driver ]; 139 + driSupport = true; 140 + }; 141 + 142 + hardware.nvidia = { 143 + 144 + # Modesetting is required. 145 + modesetting.enable = true; 146 + 147 + # Nvidia power management. Experimental, and can cause sleep/suspend to fail. 148 + # Enable this if you have graphical corruption issues or application crashes after waking 149 + # up from sleep. This fixes it by saving the entire VRAM memory to /tmp/ instead 150 + # of just the bare essentials. 151 + powerManagement.enable = true; 152 + 153 + # Fine-grained power management. Turns off GPU when not in use. 154 + # Experimental and only works on modern Nvidia GPUs (Turing or newer). 155 + powerManagement.finegrained = false; 156 + 157 + # Use the NVidia open source kernel module (not to be confused with the 158 + # independent third-party "nouveau" open source driver). 159 + # Support is limited to the Turing and later architectures. Full list of 160 + # supported GPUs is at: 161 + # https://github.com/NVIDIA/open-gpu-kernel-modules#compatible-gpus 162 + # Only available from driver 515.43.04+ 163 + # Currently alpha-quality/buggy, so false is currently the recommended setting. 164 + open = false; 165 + 166 + # Enable the Nvidia settings menu, 167 + # accessible via `nvidia-settings`. 168 + nvidiaSettings = true; 169 + 170 + # Optionally, you may need to select the appropriate driver version for your specific GPU. 171 + package = config.boot.kernelPackages.nvidiaPackages.stable; 172 + }; 173 + 174 + time.hardwareClockInLocalTime = true; 175 + 176 + 177 + console.font = "${pkgs.terminus_font}/share/consolefonts/ter-v32n.psf.gz"; 178 + console.earlySetup = true; 179 + 180 + 181 + services.fstrim.enable = true; 182 + 183 + programs.steam = { 184 + enable = true; 185 + remotePlay.openFirewall = true; 186 + dedicatedServer.openFirewall = true; 187 + localNetworkGameTransfers.openFirewall = true; 188 + }; 189 + 190 + programs.git = { 191 + enable = true; 192 + package = pkgs.gitFull; 193 + }; 194 + 195 + # Some programs need SUID wrappers, can be configured further or are 196 + # started in user sessions. 197 + # programs.mtr.enable = true; 198 + # programs.gnupg.agent = { 199 + # enable = true; 200 + # enableSSHSupport = true; 201 + # }; 202 + 203 + # List services that you want to enable: 204 + 205 + # Enable the OpenSSH daemon. 206 + # services.openssh.enable = true; 207 + 208 + # Open ports in the firewall. 209 + # networking.firewall.allowedTCPPorts = [ ... ]; 210 + # networking.firewall.allowedUDPPorts = [ ... ]; 211 + # Or disable the firewall altogether. 212 + # networking.firewall.enable = false; 213 + 214 + # This value determines the NixOS release from which the default 215 + # settings for stateful data, like file locations and database versions 216 + # on your system were taken. It‘s perfectly fine and recommended to leave 217 + # this value at the release version of the first install of this system. 218 + # Before changing this value read the documentation for this option 219 + # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). 220 + system.stateVersion = "24.05"; # Did you read the comment? 221 + 222 + }
+39
hardware-configuration.nix
··· 1 + # Do not modify this file! It was generated by ‘nixos-generate-config’ 2 + # and may be overwritten by future invocations. Please make changes 3 + # to /etc/nixos/configuration.nix instead. 4 + { config, lib, pkgs, modulesPath, ... }: 5 + 6 + { 7 + imports = 8 + [ (modulesPath + "/installer/scan/not-detected.nix") 9 + ]; 10 + 11 + boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ]; 12 + boot.initrd.kernelModules = [ ]; 13 + boot.kernelModules = [ "kvm-amd" ]; 14 + boot.extraModulePackages = [ ]; 15 + 16 + fileSystems."/" = 17 + { device = "/dev/disk/by-uuid/3a30689d-9a7b-454a-9572-5e8df3b6a76c"; 18 + fsType = "ext4"; 19 + }; 20 + 21 + fileSystems."/boot" = 22 + { device = "/dev/disk/by-uuid/BB4C-094D"; 23 + fsType = "vfat"; 24 + options = [ "fmask=0022" "dmask=0022" ]; 25 + }; 26 + 27 + swapDevices = [ ]; 28 + 29 + # Enables DHCP on each ethernet and wireless interface. In case of scripted networking 30 + # (the default) this is the recommended approach. When using systemd-networkd it's 31 + # still possible to use this option, but it's recommended to use it in conjunction 32 + # with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`. 33 + networking.useDHCP = lib.mkDefault true; 34 + # networking.interfaces.enp34s0.useDHCP = lib.mkDefault true; 35 + # networking.interfaces.enp40s0.useDHCP = lib.mkDefault true; 36 + 37 + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; 38 + hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; 39 + }