Use tmpfs for /tmp + make ISO building work (?)

This commit is contained in:
Username404-59 2026-06-22 22:27:05 +02:00
parent cbe7f4f544
commit aec346de0d
Signed by: Username404-59
GPG Key ID: F3A1878B14F5F0D7
4 changed files with 19 additions and 4 deletions

8
ISO/iso.nix Normal file
View File

@ -0,0 +1,8 @@
{ lib, ... }:
{
boot.supportedFilesystems = {
f2fs = true;
zfs = lib.mkForce false; # Pulled by ISO build for some reason, and it's broken as of writing
};
}

View File

@ -12,8 +12,8 @@
To fix problems sometimes: To fix problems sometimes:
sudo nixos-rebuild switch -I nixos-config=/etc/nixos/configuration.nix sudo nixos-rebuild switch -I nixos-config=/etc/nixos/configuration.nix
To make an ISO: To make an ISO: (https://nixos.org/manual/nixos/stable/#sec-image-nixos-rebuild-build-image)
sudo nixos-rebuild build-image sudo nixos-rebuild build-image --image-variant iso-installer
*/ */
let let
nixtamal = import ./tamal { nixtamal = import ./tamal {
@ -60,6 +60,9 @@ in
./modules/ccache.nix ./modules/ccache.nix
./modules/networking.nix ./modules/networking.nix
./modules/mesa.nix ./modules/mesa.nix
# ISO installer building stuff:
./ISO/iso.nix
]; ];
home-manager.useUserPackages = true; # Puts user packages in /etc/profiles home-manager.useUserPackages = true; # Puts user packages in /etc/profiles

View File

@ -1,4 +1,4 @@
{ pkgs, ... }: { pkgs, lib, ... }:
{ {
catppuccin.plymouth.enable = false; catppuccin.plymouth.enable = false;
@ -20,7 +20,7 @@
# 0 = Hide the OS choice for bootloaders. # 0 = Hide the OS choice for bootloaders.
# It would still be possible to open the bootloader list by pressing any key # It would still be possible to open the bootloader list by pressing any key
# It just would not appear on screen unless a key is pressed # It just would not appear on screen unless a key is pressed
timeout = 5; timeout = lib.mkForce 5; # Forced, else it doesn't work when making an ISO
}; };
plymouth = { plymouth = {

View File

@ -20,6 +20,10 @@
services.fstrim.enable = true; services.fstrim.enable = true;
boot.tmp = {
useTmpfs = true; # I'll need to disable this or make it bigger if nix builds fail because of it
};
# Link to nix-hardware configs in case I get a new laptop some day: # Link to nix-hardware configs in case I get a new laptop some day:
# https://github.com/NixOS/nixos-hardware # https://github.com/NixOS/nixos-hardware
} }