-
-
Notifications
You must be signed in to change notification settings - Fork 13.7k
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
modules/virtualisation: add shared options, merge various diskSize options #341058
base: master
Are you sure you want to change the base?
Conversation
a93cc97
to
3a4954d
Compare
@ofborg test installer |
Hm.. the installer tests failing according to ofborg seem to run fine locally and as it's a timeout, maybe hydra is overburdened or so? 🤔
|
@ofborg test installer |
Tests are still failing, due to low disk space according to ofborg. I ran all of the installer tests locally and they were successful, so I am suspecting this might be the hydra builder running low on disk space or so? |
@arianvp do you want to test those changes for the AWS AMIs before we merge? |
3a4954d
to
a6574cf
Compare
a6574cf
to
5ee2109
Compare
I can look at this after the 24th. But if other make-disk-image based images work i expect the aws one to work as well |
@ofborg test installer.clevisBcachefs |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this an attrset containing a module instead of just a module? Couldn't this just be a normal module?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The idea was to be able to pick options from virtualisation-options.nix
as needed per module - similar to how lib/nixos/systemd-unit-options.nix
.
I then switched to an attrset of modules instead of options to be able to use assertions. Suppose we could move those to the options check function if an attrset of options would be preferable for some reasons.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Assertions will work just fine. They're part of the module fixpoint like any other option, so module composition is all you need - no need to go around the module system.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's merge this so it doesn't diverge.
The main design decision of this PR is to introduce a shared diskSize attribute between various disk outputs. This makes sense because each disk output requires a new evaluation (it wouldn't make sense to import multiple profiles with conflicting target settings in the same evaluation).
I am on vacation this week, so from my point of few it doesn't hurt to wait a bit with a merge and let @arianvp check that it doesn't break the aws image |
In response to a request for help on Matrix, I built the disk image following the instructions at http://jackkelly.name/blog/archives/2020/08/30/building_and_importing_nixos_amis_on_ec2/index.html, uploaded it to S3, imported it to an EBS snapshot, created an AMI from it, launched an instance from the AMI, and SSH'd into it as I did not provide any explicit NixOS configuration. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The idea is great, but let's just use a module file and avoid the unnecessary bells and whistles. Other than that LGTM.
5ee2109
to
e3fbbcd
Compare
e3fbbcd
to
c595c5c
Compare
Description of changes
Take two of #339535, with a fix that should hopefully prevent us from blocking a channel or breaking anything else this time.
Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.