From b89749709a3a9d1b42269e45943c96f8a4b30c64 Mon Sep 17 00:00:00 2001 From: Thiago Kenji Okada Date: Wed, 18 Dec 2024 20:52:09 +0000 Subject: [PATCH] nixos/binfmt: moved from nixos/nix/qemu-compile.nix --- hosts/sankyuu-nixos/default.nix | 10 ++++++---- nixos/nix/default.nix | 1 - nixos/{nix/qemu-compile.nix => system/binfmt.nix} | 4 ++-- nixos/system/default.nix | 4 ++-- 4 files changed, 10 insertions(+), 9 deletions(-) rename nixos/{nix/qemu-compile.nix => system/binfmt.nix} (78%) diff --git a/hosts/sankyuu-nixos/default.nix b/hosts/sankyuu-nixos/default.nix index 64ebec11..0cf854d1 100644 --- a/hosts/sankyuu-nixos/default.nix +++ b/hosts/sankyuu-nixos/default.nix @@ -61,7 +61,6 @@ in nixos = { dev.enable = true; - nix.qemu-compile.enable = true; games = { enable = true; gpu = "amd"; @@ -74,9 +73,12 @@ in ssh.enable = true; tailscale.enable = true; }; - system.pageCompression = { - enable = "zswap"; - memoryPercent = 30; + system = { + binfmt.enable = true; + pageCompression = { + enable = "zswap"; + memoryPercent = 30; + }; }; }; diff --git a/nixos/nix/default.nix b/nixos/nix/default.nix index c5445443..0692cb13 100644 --- a/nixos/nix/default.nix +++ b/nixos/nix/default.nix @@ -12,7 +12,6 @@ in { imports = [ ./diff.nix - ./qemu-compile.nix ./remote-builders.nix ]; diff --git a/nixos/nix/qemu-compile.nix b/nixos/system/binfmt.nix similarity index 78% rename from nixos/nix/qemu-compile.nix rename to nixos/system/binfmt.nix index d618a10d..6f41ba79 100644 --- a/nixos/nix/qemu-compile.nix +++ b/nixos/system/binfmt.nix @@ -6,10 +6,10 @@ }: let - cfg = config.nixos.nix.qemu-compile; + cfg = config.nixos.system.binfmt; in { - options.nixos.nix.qemu-compile.enable = lib.mkEnableOption "compile other archs via QEMU"; + options.nixos.system.binfmt.enable = lib.mkEnableOption "binfmt configuration"; config = lib.mkIf cfg.enable { # Allow compilation of packages for other architectures (e.g.: ARM64) via diff --git a/nixos/system/default.nix b/nixos/system/default.nix index 7d499666..f818fba1 100644 --- a/nixos/system/default.nix +++ b/nixos/system/default.nix @@ -1,7 +1,6 @@ { config, lib, - pkgs, flake, ... }: @@ -11,8 +10,9 @@ let in { imports = [ - ./cli.nix + ./binfmt.nix ./btrfs.nix + ./cli.nix ./smart.nix ./vm.nix ];