Files
nixfiles/hosts/Console/configuration.nix
T
Emma ThorpeandClaude Opus 5 39434b3929
CI / flake (push) Skipped
CI / flake (pull_request) Successful in 7m46s
feat(hosts): add lyrathorpe-console, a living-room games machine
New x86_64 host for a 4th-gen Core i7 (Haswell) with a GTX 1070 8 GB,
wired to a television and driven with a Bluetooth controller.

Session: greetd gets an initial_session, so the machine autologins into
the gamescope Steam session at boot with no greeter and no keyboard.
Quitting Steam falls back to greetd's default_session (ReGreet), where
the ordinary Sway session is available for keyboard-and-mouse work.

Graphics: the GTX 1070 is Pascal, so it needs driver branch 580
(nvidiaPackages.legacy_580) like the Mac Pro's Quadro P400 -- the
nixpkgs default (production, 595.x) dropped Pascal support.

Games: RetroArch built through retroarch-bare.wrapper with 17 cores
covering NES through PS2, GameCube and Wii; Clone Hero; and Steam with
Proton-GE and protontricks. RetroArch's menu toggle is bound to L3+R3,
without which there is no way to exit a running core on a machine with
no keyboard.

Proton prerequisites beyond what programs.steam already arranges: the
esync file-descriptor hard limit is raised from systemd's default
524288 to 1048576 (soft limit untouched), and Proton-GE is wired in via
extraCompatPackages. vm.max_map_count already defaults high enough in
nixpkgs and needs no override.

Content lives in a shared /srv/games tree created by systemd.tmpfiles,
laid out one directory per system under roms/ using the libretro/ES-DE
naming convention, plus bios/, saves/, states/, a Steam library folder
and Clone Hero's songs. RetroArch is pointed at it declaratively.

hardware-configuration.nix is a placeholder, not a hardware scan: the
machine is not installed yet. It assumes partition labels `nixos` and
`BOOT` and must be replaced with nixos-generate-config output.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-21 17:06:21 +01:00

37 lines
1.4 KiB
Nix

# Living-room games machine: 4th-gen Core i7 (Haswell) on a UEFI board, wired to
# a television and driven from the sofa with a Bluetooth controller. Desktop host
# -- shared graphical/wired options live in ../../modules/desktop.nix; only
# host-specific settings are here. The games stack (Steam session, RetroArch,
# controllers) is in ./gaming.nix and the GPU in ./nvidia.nix. Install notes:
# see ../../docs/hosts/console.md.
{ ... }:
{
imports = [
./hardware-configuration.nix
./nvidia.nix
./gaming.nix
];
# Haswell: AVX2/FMA/BMI2, i.e. x86-64-v3. Above the fleet default (2), so this
# only records the fact -- no feature flag currently keys off level 3.
features.cpu.microarchLevel = 3;
# Ordinary PC UEFI firmware: systemd-boot, and NVRAM writes are safe here
# (unlike the Mac Pro's Apple EFI, which cannot be trusted with efibootmgr).
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
# The boot menu is unreadable from a sofa and unusable without a keyboard.
# Boot the default immediately; hold space at power-on to get the menu back.
boot.loader.timeout = 0;
# Bound the entry list so the ESP does not fill up with old generations.
boot.loader.systemd-boot.configurationLimit = 10;
networking.hostName = "Console-NixOS";
hardware.cpu.intel.updateMicrocode = true;
# See `man configuration.nix` / the stateVersion docs before changing.
system.stateVersion = "26.05";
}