Add Steam Deck (nix-deck) configuration with Jovian-NixOS and remote building
- Add Jovian-NixOS integration for Steam Deck hardware support - Create nix-deck machine configuration with SteamOS role - Add jovian-compat.nix for NixOS 25.05 compatibility (remove in 25.11+) - Create remote-build role for distributed builds - Configure zix790prors as build host - Configure nix-book and nix-deck to use remote builder with fallback - Add comprehensive setup documentation 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
43
roles/jovian-compat.nix
Normal file
43
roles/jovian-compat.nix
Normal file
@@ -0,0 +1,43 @@
|
||||
{ lib, config, ... }:
|
||||
|
||||
# Compatibility shim to provide services.logind.settings for NixOS 25.05
|
||||
# This allows Jovian-NixOS to work with stable NixOS
|
||||
# REMOVE THIS FILE when upgrading to NixOS 25.11 or later
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
nixosVersion = config.system.nixos.release;
|
||||
isCompatibleVersion = versionOlder nixosVersion "25.11";
|
||||
in
|
||||
{
|
||||
options.services.logind.settings = mkOption {
|
||||
type = types.attrsOf (types.attrsOf types.anything);
|
||||
default = {};
|
||||
description = "systemd-logind configuration. See logind.conf(5) for available options.";
|
||||
};
|
||||
|
||||
config = mkMerge [
|
||||
{
|
||||
assertions = [
|
||||
{
|
||||
assertion = isCompatibleVersion;
|
||||
message = ''
|
||||
The Jovian compatibility shim (roles/jovian-compat.nix) is only needed for NixOS 25.05 and earlier.
|
||||
You are running NixOS ${nixosVersion}.
|
||||
Please remove 'roles/jovian-compat.nix' from your flake.nix imports.
|
||||
'';
|
||||
}
|
||||
];
|
||||
}
|
||||
(mkIf (config.services.logind.settings != {}) {
|
||||
# Convert the settings to extraConfig format for older NixOS
|
||||
services.logind.extraConfig = let
|
||||
mkSection = section: settings:
|
||||
"[${section}]\n" +
|
||||
(concatStringsSep "\n" (mapAttrsToList (k: v: "${k}=${toString v}") settings));
|
||||
in
|
||||
concatStringsSep "\n\n" (mapAttrsToList mkSection config.services.logind.settings);
|
||||
})
|
||||
];
|
||||
}
|
||||
Reference in New Issue
Block a user