-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
libstore: Add apple-virt
to system features when available
#9187
libstore: Add apple-virt
to system features when available
#9187
Conversation
apple-virt
to system features when available
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.
Code looks good, would be very nice to have this feature!
Just needs change log and docs (I think we've been forgetting about these since the checklist went away...)
I'm sure that we'll adjust the implementation over time, but this at least discerns between an apple silicon bare metal machine and a tart VM.
65c6ac3
to
bb645c5
Compare
Backport failed for Please cherry-pick the changes locally. git fetch origin 2.18-maintenance
git worktree add -d .worktree/backport-9187-to-2.18-maintenance origin/2.18-maintenance
cd .worktree/backport-9187-to-2.18-maintenance
git checkout -b backport-9187-to-2.18-maintenance
ancref=$(git merge-base e58566a057692bbfbd30a6639248adfcf81df108 bb645c5d02025158c8dbb0c2a60e7cba8251f062)
git cherry-pick -x $ancref..bb645c5d02025158c8dbb0c2a60e7cba8251f062 |
@@ -714,9 +714,13 @@ public: | |||
|
|||
System features are user-defined, but Nix sets the following defaults: | |||
|
|||
- `apple-virt` | |||
|
|||
Included on darwin if virtualization is available. |
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.
Included on darwin if virtualization is available. | |
Included on Darwin if virtualization is available. |
[2.18-maintenance] Backport #9187 apple-virt
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/getting-nixos-to-work-macos-m1-2-3-aarch64-darwin/39510/1 |
I'm sure that we'll adjust the implementation over time, but this at least discerns between an apple silicon bare metal machine and a tart VM.
I haven't named the system feature after a specific technology except "apple", because the way this is checked does not seem specific to hvf or avf, as far as I know.
Motivation
VMs often don't support nested virtualization. When macOS itself is virtualized, most likely it does not support hardware virtualization for its guests.
Context
system-features
#7619Priorities
Add 👍 to pull requests you find important.