Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

disko-install: make output deterministic #830

Merged
merged 2 commits into from
Oct 15, 2024

Conversation

iFreilicht
Copy link
Contributor

Fixes #827

@matdibu FYI

@iFreilicht
Copy link
Contributor Author

Alright I had time to properly test this now, and it works!

On master:

# sudo nix run '.#disko-install' -- --dry-run --disk main /dev/asdf --flake '.#testmachine'
these 2 derivations will be built:
  /nix/store/1dxaxs72mgm3f989225hgs9w0l209cwm-disko.drv
  /nix/store/iyjdzd298y7hh2vdgn9nrqlrknzqiy64-disko.drv
building '/nix/store/1dxaxs72mgm3f989225hgs9w0l209cwm-disko.drv'...
building '/nix/store/iyjdzd298y7hh2vdgn9nrqlrknzqiy64-disko.drv'...
Would run: /nix/store/kgmcj274zh83yb7gwadvymsv69zzkhl5-disko
Would run: nixos-install --system '/nix/store/b20shmmwlg1np3hflxjklm58a77gsnrs-nixos-system-disko-machine-24.11.20240901.b833ff0' --root '/tmp/tmp.1soo4VO6rU'
# sudo nix run '.#disko-install' -- --dry-run --disk main /dev/asdf --flake '.#testmachine'
these 2 derivations will be built:
  /nix/store/456549r013s5dpa7fpjvlbgk3dyd465d-disko.drv
  /nix/store/i1xfmwrj4b74x9gwryparyq4x0a954gm-disko.drv
building '/nix/store/456549r013s5dpa7fpjvlbgk3dyd465d-disko.drv'...
building /nix/store/i1xfmwrj4b74x9gwryparyq4x0a954gm-disko.drv'...
Would run: /nix/store/0ma5r0swjwc4xsgx4s06pi9q8s6241y6-disko
Would run: nixos-install --system '/nix/store/b20shmmwlg1np3hflxjklm58a77gsnrs-nixos-system-disko-machine-24.11.20240901.b833ff0' --root '/tmp/tmp.SGnbALeYr4'

On this branch:

# sudo nix run '.#disko-install' -- --dry-run --disk main /dev/asdf --flake '.#testmachine'
these 2 derivations will be built:
  /nix/store/j185c9vxblajx27biygfpw5kqk0lzlfa-disko.drv
  /nix/store/q7wf7y4xqahvrifwyssxmsy6v64rkk49-disko.drv
building '/nix/store/j185c9vxblajx27biygfpw5kqk0lzlfa-disko.drv'...
building '/nix/store/q7wf7y4xqahvrifwyssxmsy6v64rkk49-disko.drv'...
Would run: /nix/store/vj7mdgcki9l4wdnfyp4dfswns2hlk5nd-disko
Would run: nixos-install --system '/nix/store/b20shmmwlg1np3hflxjklm58a77gsnrs-nixos-system-disko-machine-24.11.20240901.b833ff0' --root '/mnt/disko-install-root'
# sudo nix run '.#disko-install' -- --dry-run --disk main /dev/asdf --flake '.#testmachine'
Would run: /nix/store/vj7mdgcki9l4wdnfyp4dfswns2hlk5nd-disko
Would run: nixos-install --system '/nix/store/b20shmmwlg1np3hflxjklm58a77gsnrs-nixos-system-disko-machine-24.11.20240901.b833ff0' --root '/mnt/disko-install-root'

Copy link

@matdibu matdibu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thank you!

Copy link
Member

@Enzime Enzime left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM otherwise

disko-install Outdated Show resolved Hide resolved
@iFreilicht iFreilicht force-pushed the fix-disko-install-non-determinism branch from 49d17a9 to a45dd8f Compare October 15, 2024 15:13
@mergify mergify bot merged commit 9ab6ae4 into master Oct 15, 2024
5 checks passed
@mergify mergify bot deleted the fix-disko-install-non-determinism branch October 15, 2024 16:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

non-deterministic disko-install
3 participants