mirror of
https://github.com/alyraffauf/nixcfg.git
synced 2024-11-21 15:53:55 -05:00
added initial steam deck oled (mossdeep) configuration
This commit is contained in:
parent
55f5b50754
commit
fbf0668ea9
66
flake.lock
66
flake.lock
|
@ -76,7 +76,9 @@
|
|||
"hyprland-protocols": "hyprland-protocols",
|
||||
"hyprlang": "hyprlang",
|
||||
"hyprwayland-scanner": "hyprwayland-scanner",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
],
|
||||
"systems": "systems",
|
||||
"wlroots": "wlroots",
|
||||
"xdph": "xdph"
|
||||
|
@ -185,6 +187,49 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"jovian": {
|
||||
"inputs": {
|
||||
"nix-github-actions": "nix-github-actions",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1714022840,
|
||||
"narHash": "sha256-i6xZsf7Kvp1n/Sn3nqPY1MJQx0gf80OGQw32PA/aZd8=",
|
||||
"owner": "Jovian-Experiments",
|
||||
"repo": "Jovian-NixOS",
|
||||
"rev": "94def3af1d45fe4b142beda3aa59a6a98e62ce9e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "Jovian-Experiments",
|
||||
"repo": "Jovian-NixOS",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nix-github-actions": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"jovian",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1690328911,
|
||||
"narHash": "sha256-fxtExYk+aGf2YbjeWQ8JY9/n9dwuEt+ma1eUFzF8Jeo=",
|
||||
"owner": "zhaofengli",
|
||||
"repo": "nix-github-actions",
|
||||
"rev": "96df4a39c52f53cb7098b923224d8ce941b64747",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "zhaofengli",
|
||||
"ref": "matrix-name",
|
||||
"repo": "nix-github-actions",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixos-hardware": {
|
||||
"locked": {
|
||||
"lastModified": 1713864415,
|
||||
|
@ -202,22 +247,6 @@
|
|||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1713714899,
|
||||
"narHash": "sha256-+z/XjO3QJs5rLE5UOf015gdVauVRQd2vZtsFkaXBq2Y=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "6143fc5eeb9c4f00163267708e26191d1e918932",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1713895582,
|
||||
"narHash": "sha256-cfh1hi+6muQMbi9acOlju3V1gl8BEaZBXBR9jQfQi4U=",
|
||||
|
@ -239,8 +268,9 @@
|
|||
"home-manager": "home-manager",
|
||||
"hyprland": "hyprland",
|
||||
"impermanence": "impermanence",
|
||||
"jovian": "jovian",
|
||||
"nixos-hardware": "nixos-hardware",
|
||||
"nixpkgs": "nixpkgs_2"
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
|
|
24
flake.nix
24
flake.nix
|
@ -19,10 +19,18 @@
|
|||
impermanence.url = "github:nix-community/impermanence";
|
||||
|
||||
# Latest Hyprland
|
||||
hyprland.url = "github:hyprwm/Hyprland";
|
||||
hyprland = {
|
||||
url = "github:hyprwm/Hyprland";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
# Pre-baked hardware support for various devices.
|
||||
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
|
||||
|
||||
jovian = {
|
||||
url = "github:Jovian-Experiments/Jovian-NixOS";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
};
|
||||
|
||||
nixConfig = {
|
||||
|
@ -40,6 +48,7 @@
|
|||
impermanence,
|
||||
disko,
|
||||
hyprland,
|
||||
jovian,
|
||||
...
|
||||
}: {
|
||||
homeConfigurations = {
|
||||
|
@ -54,6 +63,19 @@
|
|||
};
|
||||
|
||||
nixosConfigurations = {
|
||||
# Steam Deck OLED
|
||||
mossdeep = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = {inherit inputs;};
|
||||
modules = [
|
||||
disko.nixosModules.disko
|
||||
jovian.nixosModules.default
|
||||
home-manager.nixosModules.home-manager
|
||||
./hosts/mossdeep
|
||||
./nixosModules
|
||||
];
|
||||
};
|
||||
|
||||
# Framework 13 with AMD Ryzen 7640U and 32GB RAM.
|
||||
lavaridge = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
|
|
66
hosts/mossdeep/default.nix
Normal file
66
hosts/mossdeep/default.nix
Normal file
|
@ -0,0 +1,66 @@
|
|||
# Framework Laptop 13 with AMD Ryzen 7640U, 32GB RAM, 1TB SSD.
|
||||
{
|
||||
inputs,
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
./hardware-configuration.nix # Include the results of the hardware scan.
|
||||
./home.nix
|
||||
./disko.nix
|
||||
];
|
||||
|
||||
boot = {
|
||||
# Bootloader.
|
||||
loader.systemd-boot.enable = true;
|
||||
loader.efi.canTouchEfiVariables = true;
|
||||
|
||||
# Use latest Linux kernel.
|
||||
kernelPackages = pkgs.linuxPackages_latest;
|
||||
};
|
||||
|
||||
networking.hostName = "mossdeep"; # Define your hostname.
|
||||
|
||||
services = {
|
||||
fwupd.enable = true;
|
||||
};
|
||||
|
||||
alyraffauf = {
|
||||
system = {
|
||||
plymouth.enable = true;
|
||||
zramSwap = {enable = true;};
|
||||
};
|
||||
user = {
|
||||
aly.enable = true;
|
||||
dustin.enable = false;
|
||||
};
|
||||
desktop = {
|
||||
enable = true;
|
||||
hyprland.enable = true;
|
||||
};
|
||||
apps = {
|
||||
steam.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
jovian = {
|
||||
steam = {
|
||||
user = "aly";
|
||||
enable = true;
|
||||
autoStart = true;
|
||||
desktopSession = "hyprland";
|
||||
};
|
||||
decky-loader = {
|
||||
user = "aly";
|
||||
enable = true;
|
||||
};
|
||||
devices.steamdeck.enable = true;
|
||||
steamos.useSteamOSConfig = true;
|
||||
};
|
||||
|
||||
users.users.aly.hashedPassword = "$y$j9T$koxhEzkA4pYLsyIqZBTWM0$N8VW.JTM.HZZgNm7XgTxTXRzvYd7veA7TojG0gKOzO2";
|
||||
|
||||
system.stateVersion = "23.11"; # Did you read the comment?
|
||||
}
|
56
hosts/mossdeep/disko.nix
Normal file
56
hosts/mossdeep/disko.nix
Normal file
|
@ -0,0 +1,56 @@
|
|||
{
|
||||
disko.devices = {
|
||||
disk = {
|
||||
vdb = {
|
||||
type = "disk";
|
||||
device = "/dev/nvme0n1";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
ESP = {
|
||||
priority = 1;
|
||||
name = "ESP";
|
||||
start = "1M";
|
||||
end = "1024M";
|
||||
type = "EF00";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "vfat";
|
||||
mountpoint = "/boot";
|
||||
};
|
||||
};
|
||||
root = {
|
||||
size = "100%";
|
||||
content = {
|
||||
type = "btrfs";
|
||||
extraArgs = ["-f"]; # Override existing partition
|
||||
# Subvolumes must set a mountpoint in order to be mounted,
|
||||
# unless their parent is mounted
|
||||
subvolumes = {
|
||||
# Subvolume name is different from mountpoint
|
||||
"rootfs" = {mountpoint = "/";};
|
||||
# For use with future impermanence setups
|
||||
"persist" = {
|
||||
mountpoint = "/persist";
|
||||
mountOptions = ["compress=zstd" "noatime"];
|
||||
};
|
||||
# Subvolume name is the same as the mountpoint
|
||||
"home" = {
|
||||
mountOptions = ["compress=zstd"];
|
||||
mountpoint = "/home";
|
||||
};
|
||||
# Parent is not mounted so the mountpoint must be set
|
||||
"nix" = {
|
||||
mountOptions = ["compress=zstd" "noatime"];
|
||||
mountpoint = "/nix";
|
||||
};
|
||||
};
|
||||
mountpoint = "/partition-root";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
31
hosts/mossdeep/hardware-configuration.nix
Normal file
31
hosts/mossdeep/hardware-configuration.nix
Normal file
|
@ -0,0 +1,31 @@
|
|||
# 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 = ["nvme" "xhci_pci" "usb_storage" "sd_mod"];
|
||||
boot.initrd.kernelModules = ["amdgpu"];
|
||||
boot.kernelModules = ["kvm-amd"];
|
||||
boot.extraModulePackages = [];
|
||||
|
||||
hardware.opengl.driSupport = true;
|
||||
|
||||
# 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.enp193s0f3u1c2.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp1s0.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.amd.updateMicrocode =
|
||||
lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
12
hosts/mossdeep/home.nix
Normal file
12
hosts/mossdeep/home.nix
Normal file
|
@ -0,0 +1,12 @@
|
|||
{
|
||||
inputs,
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
home-manager.users.aly = {
|
||||
imports = [../../homeManagerModules ../../aly.nix];
|
||||
home.stateVersion = "23.11";
|
||||
};
|
||||
}
|
Loading…
Reference in a new issue