diff --git a/README.md b/README.md index 4d4a964..882c199 100644 --- a/README.md +++ b/README.md @@ -2,3 +2,12 @@ This holds my .nix files for NixOS +Nix files: (nix-configs/) + +- `configuration.nix` : This is the main file for the base system including some applications that I use +- `plasma.nix` : This file is for the desktop, login manager and other KDE applications +- `programs.nix` : This file adds applications like Slack, Discord and virt-manager including turning on the services +- `oryp6.nix` : This file is mainly for my System76 Oryx Pro (oryp6) to add and enable the NVIDIA driver from stable +- `hp-omen.nix` : This file is mainly for my HP Omen to add and enable the NVIDIA driver from stable +- `rpi4.nix` : This file is to configure a Raspberry Pi 4B +- `unstable.nix` : This file has the applications that need to be from unstable to work like ProtonVPN software diff --git a/systems/rpi4-example.nix b/systems/rpi4-example.nix new file mode 100644 index 0000000..1903f87 --- /dev/null +++ b/systems/rpi4-example.nix @@ -0,0 +1,56 @@ +{ config, pkgs, lib, ... }: + +let + SSID = "Honeycutt-5G"; + SSIDpassword = "Frappe92"; + interface = "wlan0"; + hostname = "NixOS"; +in { + imports = ["${fetchTarball "https://github.com/NixOS/nixos-hardware/archive/936e4649098d6a5e0762058cb7687be1b2d90550.tar.gz" }/raspberry-pi/4"]; + + fileSystems = { + "/" = { + device = "/dev/disk/by-label/NIXOS_SD"; + fsType = "ext4"; + options = [ "noatime" ]; + }; + }; + + networking = { + hostName = "NixOS"; + networkmanager.enable = true; + + wireless = { + enable = true; + networks."${SSID}".psk = SSIDpassword; + interfaces = [ interface ]; + }; + }; + + # Set your time zone. + time.timeZone = "America/Denver"; + + environment.systemPackages = with pkgs; [ vim ]; + + services.openssh.enable = true; + + # Define user accounts + users.extraUsers.aaronh = { + description = "Aaron Honeycutt"; + home = "/home/aaronh"; + extraGroups = [ "wheel" "networkmanager" "adm"]; + isNormalUser = true; + hashedPassword = "$6$aAcbLtqiqzySifls$jdKMOQjoWITHD/dWNNZVUH/qNc6aoJ7v4zYofi0U7IJSVTbmOfChS3mzaJbp57AodjdPNKPrnrip8Nlh2Qanx."; + }; + + # Enable GPU acceleration + hardware.raspberry-pi."4".fkms-3d.enable = true; + + services.xserver = { + enable = true; + displayManager.lightdm.enable = true; + desktopManager.xfce.enable = true; + }; + + hardware.pulseaudio.enable = true; +} diff --git a/systems/rpi4.nix b/systems/rpi4.nix new file mode 100644 index 0000000..b22154d --- /dev/null +++ b/systems/rpi4.nix @@ -0,0 +1,83 @@ +{ config, pkgs, lib, ... }: + +{ + imports = + [ + "${fetchTarball "https://github.com/NixOS/nixos-hardware/archive/936e4649098d6a5e0762058cb7687be1b2d90550.tar.gz" }/raspberry-pi/4" +# ./programs.nix + ]; + + fileSystems = { + "/" = { + device = "/dev/disk/by-label/NIXOS_SD"; + fsType = "ext4"; + options = [ "noatime" ]; + }; + }; + + networking = { + hostName = "NixOS-rpi4"; + networkmanager.enable = true; + }; + + # Set your time zone. + time.timeZone = "America/Denver"; + + environment.systemPackages = + with pkgs; + [ + firefox + fish + git + neofetch + thunderbird + restic + wget + ]; + + services.openssh.enable = true; + + # Define user accounts + users.extraUsers.aaronh = { + description = "Aaron Honeycutt"; + home = "/home/aaronh"; + extraGroups = [ "wheel" "networkmanager" "adm"]; + isNormalUser = true; + hashedPassword = "$6$aAcbLtqiqzySifls$jdKMOQjoWITHD/dWNNZVUH/qNc6aoJ7v4zYofi0U7IJSVTbmOfChS3mzaJbp57AodjdPNKPrnrip8Nlh2Qanx."; + }; + + # Enable Pipewire + security.rtkit.enable = true; + services.pipewire = { + enable = true; + alsa.enable = true; + alsa.support32Bit = true; + pulse.enable = true; + }; + + # Turn off PulseAudio + hardware.pulseaudio.enable = false; + + # Enable Bluetooth + hardware.bluetooth.enable = true; + + # Enable CUPS + services.printing.enable = true; + + # Enable GPU acceleration + hardware.raspberry-pi."4".fkms-3d.enable = true; + + # Allow Unfree + nixpkgs.config.allowUnfree = true; + + # GNOME + services.xserver.enable = true; + services.xserver.displayManager.gdm.enable = true; + services.xserver.desktopManager.gnome.enable = true; + + # System + system.stateVersion = "22.11"; + system.autoUpgrade.enable = true; + + +}