I dno what im oing
This commit is contained in:
parent
a1780e0f07
commit
7168e4c0c7
35 changed files with 120 additions and 16 deletions
61
system/ooksx1/hardware-configuration.nix
Normal file
61
system/ooksx1/hardware-configuration.nix
Normal file
|
|
@ -0,0 +1,61 @@
|
|||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/db84a41f-6094-46b1-b98a-26e03afc18e1";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=root" ];
|
||||
};
|
||||
|
||||
boot.initrd.luks.devices."cryptroot".device = "/dev/disk/by-uuid/3ea21f10-f705-457c-8366-a8268f658ba6";
|
||||
|
||||
fileSystems."/nix" =
|
||||
{ device = "/dev/disk/by-uuid/db84a41f-6094-46b1-b98a-26e03afc18e1";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=nix" ];
|
||||
};
|
||||
|
||||
fileSystems."/persist" =
|
||||
{ device = "/dev/disk/by-uuid/db84a41f-6094-46b1-b98a-26e03afc18e1";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=persist" ];
|
||||
};
|
||||
|
||||
fileSystems."/swap" =
|
||||
{ device = "/dev/disk/by-uuid/db84a41f-6094-46b1-b98a-26e03afc18e1";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=swap" ];
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/45D8-8DC3";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
swapDevices = [ ];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
# still possible to use this option, but it's recommended to use it in conjunction
|
||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.enp0s31f6.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp4s0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wwp0s20f0u2c2.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
||||
284
system/ooksx1/laptop.nix
Normal file
284
system/ooksx1/laptop.nix
Normal file
|
|
@ -0,0 +1,284 @@
|
|||
|
||||
|
||||
|
||||
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
# Imports
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
{
|
||||
imports =
|
||||
[ # Include the results of the hardware scan
|
||||
./hardware-configuration.nix
|
||||
];
|
||||
|
||||
# Bootloader
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
|
||||
|
||||
# Nix Settings
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
nix = {
|
||||
settings = {
|
||||
auto-optimise-store = true;
|
||||
experimental-features = "nix-command flakes";
|
||||
};
|
||||
|
||||
|
||||
# Garbage Collection
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
gc = {
|
||||
automatic = true;
|
||||
dates = "weekly";
|
||||
options = "--delete-older-than 2d";
|
||||
};
|
||||
};
|
||||
|
||||
# System Architecture
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
nixpkgs.system = "x86_64-linux";
|
||||
|
||||
|
||||
# Networking
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
networking = {
|
||||
hostName = "ooksthink"; # Define your hostname.
|
||||
networkmanager.enable = true; # Easiest to use and most distros use this by default.
|
||||
};
|
||||
|
||||
|
||||
# Time Zone
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
time.timeZone = "Pacific/Auckland";
|
||||
|
||||
# Localization
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
i18n.defaultLocale = "en_US.UTF-8";
|
||||
|
||||
# X Server
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
services.xserver = {
|
||||
enable = true;
|
||||
displayManager = {
|
||||
defaultSession = null;
|
||||
startx.enable = true;
|
||||
};
|
||||
# displayManager.gdm = {
|
||||
# enable = true;
|
||||
# wayland = true;
|
||||
# };
|
||||
};
|
||||
|
||||
# X11 Keymap
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
# services.xserver.layout = "us";
|
||||
# services.xserver.xkbOptions = "eurosign:e,caps:escape";
|
||||
|
||||
# Printing
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
# services.printing.enable = true;
|
||||
|
||||
# Sound
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
sound.enable = false;
|
||||
hardware.pulseaudio.enable = false;
|
||||
|
||||
# Touchpad
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
# services.xserver.libinput.enable = true;
|
||||
|
||||
# User
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
users.users = {
|
||||
ooks = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [ "wheel" ];
|
||||
shell = pkgs.fish;
|
||||
|
||||
# User Packages
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
packages = with pkgs; [
|
||||
firefox
|
||||
tree
|
||||
hyprland
|
||||
kitty
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
# System Environment
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
environment = {
|
||||
binsh = "${pkgs.dash}/bin/dash";
|
||||
shells = with pkgs; [ fish ];
|
||||
systemPackages = with pkgs; [
|
||||
# Editor
|
||||
# ------
|
||||
neovim
|
||||
# Utility
|
||||
# ------
|
||||
wget
|
||||
dash
|
||||
neofetch
|
||||
glib
|
||||
xdg-utils
|
||||
pciutils
|
||||
gdb
|
||||
killall
|
||||
jetbrains-mono
|
||||
cargo
|
||||
p7zip
|
||||
joshuto
|
||||
zip
|
||||
rar
|
||||
btop
|
||||
git
|
||||
libnotify
|
||||
dunst
|
||||
wl-clipboard
|
||||
wlr-randr
|
||||
wayland
|
||||
wayland-scanner
|
||||
wayland-utils
|
||||
egl-wayland
|
||||
wayland-protocols
|
||||
wev
|
||||
alsa-lib
|
||||
alsa-utils
|
||||
flac
|
||||
pulsemixer
|
||||
linux-firmware
|
||||
lxappearance
|
||||
pkgs.sway-contrib.grimshot
|
||||
flameshot
|
||||
grim
|
||||
];
|
||||
};
|
||||
|
||||
# Fonts
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
fonts.fonts = with pkgs; [
|
||||
(nerdfonts.override { fonts = [ "JetBrainsMono" ]; })
|
||||
];
|
||||
|
||||
# Programs
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
programs.mtr.enable = true;
|
||||
programs.gnupg.agent = {
|
||||
enable = true;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
programs.hyprland = {
|
||||
enable = true;
|
||||
xwayland.enable = true;
|
||||
};
|
||||
programs.fish = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
# Services
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
security.rtkit.enable = true;
|
||||
|
||||
services = {
|
||||
pipewire = {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
jack.enable = true;
|
||||
wireplumber.enable = true;
|
||||
};
|
||||
dbus.packages = [ pkgs.gcr ];
|
||||
getty.autologinUser = "ooks";
|
||||
auto-cpufreq = {
|
||||
enable = true;
|
||||
settings = {
|
||||
battery = {
|
||||
governor = "powersave";
|
||||
turbo = "never";
|
||||
};
|
||||
charger = {
|
||||
governor = "performance";
|
||||
turbo = "auto";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
systemd = {
|
||||
user.services.polkit-gnome-authentication-agent-1 = {
|
||||
description = "polkit-gnome-authentication-agent-1";
|
||||
wantedBy = [ "graphical-session.target" ];
|
||||
wants = [ "graphical-session.target" ];
|
||||
after = [ "graphical-session.target" ];
|
||||
serviceConfig = {
|
||||
Type = "simple";
|
||||
ExecStart = "${pkgs.polkit_gnome}/libexec/polkit-gnome-authentication-agent-1";
|
||||
Restart = "on-failure";
|
||||
RestartSec = 1;
|
||||
TimeoutStopSec = 10;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# Security
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
security.polkit.enable = true;
|
||||
security.sudo = {
|
||||
enable = true;
|
||||
extraConfig = ''
|
||||
ooks ALL=(ALL) NOPASSWD:ALL
|
||||
'';
|
||||
};
|
||||
|
||||
|
||||
# D-Bus
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
services.dbus.enable = true;
|
||||
|
||||
# Firewall
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
# networking.firewall.allowedTCPPorts = [ ... ];
|
||||
# networking.firewall.allowedUDPPorts = [ ... ];
|
||||
# Or disable the firewall altogether.
|
||||
# networking.firewall.enable = false;
|
||||
|
||||
# System Version
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
system = {
|
||||
autoUpgrade = {
|
||||
enable = false;
|
||||
channel = "https://nixos.org/channels/nix-unstable";
|
||||
};
|
||||
stateVersion = "23.11";
|
||||
copySystemConfiguration = false;
|
||||
};
|
||||
}
|
||||
0
system/ooksx1/modules/networking.nix
Normal file
0
system/ooksx1/modules/networking.nix
Normal file
78
system/ooksx1/modules/packages.nix
Normal file
78
system/ooksx1/modules/packages.nix
Normal file
|
|
@ -0,0 +1,78 @@
|
|||
|
||||
{ pkgs, ... }
|
||||
{
|
||||
# System Packages
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
environment = {
|
||||
binsh = with pkgs; [ fish ]
|
||||
systemPackages = with pkgs; [
|
||||
# Editor
|
||||
neovim
|
||||
# Utility
|
||||
wget
|
||||
neofetch
|
||||
glib
|
||||
xdg-utils
|
||||
killall
|
||||
zip
|
||||
rar
|
||||
btop
|
||||
p7zip
|
||||
git
|
||||
pciutils
|
||||
gdb
|
||||
dash
|
||||
curl
|
||||
# Programming
|
||||
cargo
|
||||
# Fonts
|
||||
jetbrains-mono
|
||||
# File browsers
|
||||
ranger
|
||||
joshuto
|
||||
# Wayland
|
||||
wayland
|
||||
wayland-scanner
|
||||
wayland-utils
|
||||
egl-wayland
|
||||
wayland-protocols
|
||||
wev # Wayland window debugger
|
||||
wl-clipboard # Wayland clipboard
|
||||
wlr-randr
|
||||
# Firmware
|
||||
linux-firmware
|
||||
# Audio
|
||||
alsa-lib
|
||||
alsa-utils
|
||||
flac
|
||||
pulsemixer
|
||||
# Appearance
|
||||
lxappearance
|
||||
# Screenshot
|
||||
pkgs.sway-contrib.grimshot
|
||||
flameshot
|
||||
grim
|
||||
# Notification
|
||||
dunst
|
||||
libnotify
|
||||
];
|
||||
};
|
||||
|
||||
# Programs
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
programs.mtr.enable = true
|
||||
programs.gnupg.agent = {
|
||||
enable = true;
|
||||
enabeSSHSupport = true;
|
||||
};
|
||||
programs.hyprland = {
|
||||
enable = true;
|
||||
xwayland.enable = true;
|
||||
};
|
||||
programs.fish = {
|
||||
enable = true
|
||||
};
|
||||
|
||||
|
||||
46
system/ooksx1/modules/security.nix
Normal file
46
system/ooksx1/modules/security.nix
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
|
||||
|
||||
|
||||
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
|
||||
{
|
||||
programs.gnupg.agent = {
|
||||
enable = true;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
|
||||
security = {
|
||||
rtkit = {
|
||||
enable = true;
|
||||
};
|
||||
polkit = {
|
||||
enable = true;
|
||||
};
|
||||
sudo = {
|
||||
enable = true;
|
||||
extraConfig = ''
|
||||
ooks ALL=(ALL) NOPASSWD:ALL
|
||||
'';
|
||||
}
|
||||
};
|
||||
|
||||
systemd = {
|
||||
user.services.polkit-gnome-authentication-agent-1 = {
|
||||
description = "polkit-gnome-authentication-agent-1";
|
||||
wantedBy = [ "graphical-session.target" ];
|
||||
wants = [ "graphical-session.target" ];
|
||||
after = [ "graphical-session.target" ];
|
||||
serviceConfig = {
|
||||
Type = "simple";
|
||||
ExecStart = "${pkgs.polkit_gnome}/libexec/polkit-gnome-authentication-agent-1";
|
||||
Restart = "on-failure";
|
||||
RestartSec = 1;
|
||||
TimeoutStopSec = 10;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue