mirror of
https://github.com/TheWanderingCrow/CrOS.git
synced 2026-01-10 17:34:05 -05:00
add dragneel host
This commit is contained in:
parent
979ead7d35
commit
63fd280927
11 changed files with 169 additions and 1 deletions
11
flake.nix
11
flake.nix
|
|
@ -74,6 +74,17 @@
|
|||
]
|
||||
++ baseModules;
|
||||
};
|
||||
################
|
||||
# Wife Desktop #
|
||||
################
|
||||
Dragneel = nixpkgs.lib.nixosSystem {
|
||||
specialArgs = {inherit inputs;};
|
||||
modules =
|
||||
[
|
||||
./hosts/Dragneel
|
||||
]
|
||||
++ baseModules;
|
||||
};
|
||||
###############
|
||||
# Home Server #
|
||||
###############
|
||||
|
|
|
|||
22
hosts/Dragneel/default.nix
Normal file
22
hosts/Dragneel/default.nix
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
../../modules
|
||||
];
|
||||
|
||||
networking.hostName = "Dragneel";
|
||||
|
||||
user.dragneel.enable = true;
|
||||
|
||||
desktop.kde.enable = true;
|
||||
|
||||
module.gui.enable = true;
|
||||
module.gaming.enable = true;
|
||||
|
||||
programs.noisetorch.enable = true;
|
||||
}
|
||||
56
hosts/Dragneel/hardware-configuration.nix
Normal file
56
hosts/Dragneel/hardware-configuration.nix
Normal file
|
|
@ -0,0 +1,56 @@
|
|||
# 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 = ["sg" "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod"];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-amd"];
|
||||
boot.extraModulePackages = [];
|
||||
boot.loader = {
|
||||
systemd-boot.enable = true;
|
||||
efi = {
|
||||
canTouchEfiVariables = true;
|
||||
};
|
||||
};
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-label/nixos";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" = {
|
||||
device = "/dev/disk/by-label/boot";
|
||||
fsType = "vfat";
|
||||
options = ["fmask=0022" "dmask=0022"];
|
||||
};
|
||||
|
||||
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.enp4s0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp8s0.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
hardware.amdgpu = {
|
||||
initrd.enable = true;
|
||||
amdvlk.enable = true;
|
||||
opencl.enable = true;
|
||||
};
|
||||
|
||||
hardware.rtl-sdr.enable = true;
|
||||
}
|
||||
|
|
@ -14,6 +14,9 @@
|
|||
#trusted-public-keys = ["wce-cache:s5otDeH048aZEGwQ2EQn6UfFJn6YgP71bcOok1jX1Q0="];
|
||||
};
|
||||
|
||||
users.mutableUsers = false;
|
||||
users.users.root.hashedPassword = "$y$j9T$pEz.3JBh6Ft3FIYrp14Ti1$RQsOWum40HbwEb7t69LGjUCh6E9w/ANi7lNIopGsu0A";
|
||||
|
||||
environment.variables = {
|
||||
EDITOR = "nvim";
|
||||
VISUAL = "nvim";
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@
|
|||
imports = [
|
||||
# Wayland desktops here
|
||||
./wayland/sway.nix
|
||||
./wayland/kde.nix
|
||||
|
||||
# X11 desktops here
|
||||
./x11/i3.nix
|
||||
|
|
|
|||
17
modules/desktops/wayland/kde.nix
Normal file
17
modules/desktops/wayland/kde.nix
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
inputs,
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
lib.mkIf config.desktop.kde.enable {
|
||||
services.desktopManager.plasma6 = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
services.displayManager.sddm = {
|
||||
enable = true;
|
||||
wayland.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
@ -32,6 +32,10 @@
|
|||
enable = lib.mkEnableOption "enable crow";
|
||||
home.enable = lib.mkEnableOption "enable home configuration";
|
||||
};
|
||||
dragneel = {
|
||||
enable = lib.mkEnableOption "enable dragneel";
|
||||
home.enable = lib.mkEnableOption "enable home configuration";
|
||||
};
|
||||
overseer = {
|
||||
enable = lib.mkEnableOption "enable container overseer user";
|
||||
};
|
||||
|
|
@ -48,6 +52,7 @@
|
|||
swayfx.enable = lib.mkEnableOption "enable sway with eye candy";
|
||||
niri.enable = lib.mkEnableOption "enable niri window manager";
|
||||
i3.enable = lib.mkEnableOption "enables i3";
|
||||
kde.enable = lib.mkEnableOption "KDE with Plasma6";
|
||||
};
|
||||
|
||||
service = {
|
||||
|
|
@ -89,6 +94,10 @@
|
|||
enable = lib.mkDefault false;
|
||||
home.enable = lib.mkDefault config.user.crow.enable;
|
||||
};
|
||||
dragneel = {
|
||||
enable = lib.mkDefault false;
|
||||
home.enable = lib.mkDefault config.user.dragneel.enable;
|
||||
};
|
||||
overseer = {
|
||||
enable = lib.mkDefault false;
|
||||
};
|
||||
|
|
@ -106,6 +115,7 @@
|
|||
swayfx.enable = lib.mkDefault false;
|
||||
niri.enable = lib.mkDefault false;
|
||||
i3.enable = lib.mkDefault false;
|
||||
kde.enable = lib.mkDefault false;
|
||||
};
|
||||
|
||||
service = {
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
}: {
|
||||
users.users.crow = lib.mkIf config.user.crow.enable {
|
||||
isNormalUser = true;
|
||||
initialPassword = "changeme";
|
||||
hashedPassword = "$y$j9T$wDC7wMJxCLNvdf8L8s6jZ.$U06F381x07fzu.updEsoegiWtbFvsrRJ7DLN9gR7un0";
|
||||
extraGroups = ["wheel" "networkmanager" "audio" "plugdev" "dialout"];
|
||||
openssh.authorizedKeys.keyFiles = [
|
||||
inputs.nix-secrets.keys.default
|
||||
|
|
|
|||
9
modules/users/dragneel/default.nix
Normal file
9
modules/users/dragneel/default.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
./user.nix
|
||||
];
|
||||
}
|
||||
20
modules/users/dragneel/home.nix
Normal file
20
modules/users/dragneel/home.nix
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
{
|
||||
osConfig,
|
||||
config,
|
||||
inputs,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
imports = [];
|
||||
home = {
|
||||
username = "dragneel";
|
||||
homeDirectory = "/home/dragneel";
|
||||
stateVersion = "24.05";
|
||||
};
|
||||
|
||||
xdg = {
|
||||
configHome = "/home/dragneel/.config";
|
||||
enable = true;
|
||||
};
|
||||
}
|
||||
19
modules/users/dragneel/user.nix
Normal file
19
modules/users/dragneel/user.nix
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
inputs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
lib.mkIf config.user.dragneel.enable {
|
||||
users.users.dragneel = {
|
||||
isNormalUser = true;
|
||||
hashedPassword = "$y$j9T$QA39xfvBrwChIi7CBsLgn.$jyWUKiP6QGY4rMtFTcBZgw7s1IJdiaIK6ZUwnU3Wmj7";
|
||||
group = "wheel";
|
||||
extraGroups = ["wheel" "networkmanager" "audio" "plugdev"];
|
||||
openssh.authorizedKeys.keyFiles = [
|
||||
inputs.nix-secrets.keys.default
|
||||
];
|
||||
};
|
||||
|
||||
home-manager.users.dragneel = ./home.nix;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue