Skip to content

Commit

Permalink
nixos/image: use erofs-utils' --hard-dereference flag
Browse files Browse the repository at this point in the history
to make image builds reproducible between systems with nix store optimization enables/disabled.

Signed-off-by: Paul Meyer <[email protected]>
  • Loading branch information
katexochen committed Dec 20, 2024
1 parent 21b73cf commit d4b3a09
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packages/nixos/image.nix
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,12 @@ in
name = "image-podvm-gpu";
inherit (config.system.image) version;

mkfsOptions.erofs = [
# Dereference hardlinks to avoid different number of inodes between images
# built on systems with nix store optimization enabled and disabled.
"--hard-dereference"
];

# This defines the actual partition layout.
partitions = {
# EFI System Partition, holds the UKI.
Expand Down

0 comments on commit d4b3a09

Please sign in to comment.