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

host: add deault implementation for system.build.isoImage target (per… #102

Merged
merged 4 commits into from
Feb 2, 2021

Conversation

blaggacao
Copy link
Contributor

@blaggacao blaggacao commented Jan 25, 2021

… host)

This is a more generic implementation to ISO builds, similar to what nixpkgs/flake.nix does with lib.nixosSystem for VMs.

In a follow up PR, I'll implement netboot and sd card flashing (in principle)
as prototyped here: numtide/flake-utils@d1ff2f0


Looks promising:

$ nix build .#nixosConfigurations.NixOS.config.system.build.iso
$ nix build .#nixosConfigurations.ci.config.system.build.iso
$ ls result/iso
nixos-NixOS-20.09pre-git-x86_64-linux.iso
# ... still waiting for results from ci build
# ... wait a minute: wouldn't this be a strategy for ci targets, too? (it looks like so) ... going to stop it

The wireless conflict (2nd commit) comes from the installation device profile


EDIT: I fixed flk iso NixOS in latest force-push

@blaggacao
Copy link
Contributor Author

preview idea for possible sd + netboot support: blaggacao#1

@blaggacao blaggacao force-pushed the da/iso-sd-netboot branch 4 times, most recently from c51eb30 to 00bb079 Compare January 27, 2021 14:35
@nrdxp
Copy link
Collaborator

nrdxp commented Jan 27, 2021

This looks great. Anything else you want to implement, or is it ready for merge?

@blaggacao
Copy link
Contributor Author

blaggacao commented Jan 27, 2021

This is ready for merge, going forward you might put a close eye on what would be necessary here: https://github.com/nrdxp/nixflk/pull/102/files#diff-9e2394d5d965447692e8b09d0235b8fdd8426071c2537d0e4a7e4786d9fcf97eR32-R33

Please also build on your machine to check if everything works (it worked over here).

I'm still fighting with sd-images for similar reasons (option overrides) on blaggacao#1 (while netboot seems good).

I might open another PR with netboot support, soonish though.

@nrdxp
Copy link
Collaborator

nrdxp commented Jan 27, 2021

I'll give it a test drive and see if everything works out. If so I'll go ahead and merge.

@nrdxp nrdxp self-requested a review January 27, 2021 17:57
Copy link
Collaborator

@nrdxp nrdxp left a comment

Choose a reason for hiding this comment

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

Basically just wondering if we can break out the logic in lib/default.nix instead of clutter the head of hosts/default.nix. Other than that, everything seems to work wonderfully.

hosts/default.nix Outdated Show resolved Hide resolved
@blaggacao
Copy link
Contributor Author

For future reference / inspiration: https://github.com/nix-community/nixos-generators, specifically: nix-community/nixos-generators#85

Copy link
Collaborator

@nrdxp nrdxp left a comment

Choose a reason for hiding this comment

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

Oh, also please update the README.md to reflect the new changes.

@blaggacao
Copy link
Contributor Author

Can you review again:

  • Readme updated (force push)
  • moved to ./lib

@blaggacao blaggacao requested a review from nrdxp January 28, 2021 02:13
Copy link
Collaborator

@nrdxp nrdxp left a comment

Choose a reason for hiding this comment

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

Sent a PR with some small style fixups to keep the line limit under control. Other than that, this looks ready to merge!

@nrdxp nrdxp merged commit 4ae99af into divnix:template Feb 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants