-
-
Notifications
You must be signed in to change notification settings - Fork 157
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
[RFC 0139] Declarative filesystem layouts #139
base: master
Are you sure you want to change the base?
Conversation
I will try to chime in when I find some time, but if you want to do a jitsi session or something like that I could talk a bit about plans to integrate disko into nixpkgs. maybe one can sketch out the RFC after that :) |
The idea of this is to use the Nix language to describe the hard disk layout? |
Yes, ideally in such a way as to make sure the info can be used to both apply the structure (using any of the standard tools, like |
One thing to consider in your write-up: what happens when the end-user changes the described layout on a running system? In the past, non-commital lightweight discussions about that topic always ended-up at that dead-end, where declaratively describing this inherently stateful thing can't be handled through the lifecycle of NixOS systems, except at the very start before the first generation is booted, otherwise known as "installation". Again, something to consider, please continue :). |
Well we can't really change the filesystem of the system we are running on without losing a bunch of files. But maybe we can add a flag (similiar to how we handle the bootloader) to try to force the application of the filesystem changes. We could then kexec into a live system. rescue some files we care about, reformat the disks and then bootup into the new system. with a lot of files lost though |
A recent MacOS update forced filesystem changes on all devices (including removing Maybe this could work:
EDIT: Actually, it's probably a bad idea to use the |
Could Ignition serve as an example? |
Note that we recently merged |
Excellent! @nikstur Thank you! Especially like the test. Is this going to be in 23.05? Is there a PR with documentation on the way? And is it possible to use this to bootstrap a NixOS install? |
Any status on this? |
@nyabinary There's been a lot of excellent feedback, and it sounds like people would be interested in the feature, but I don't feel qualified to lead this to completion by myself. As far as I'm concerned, there are a few possible next steps. Off the top of my head and in no particular order:
|
I feel like this plus impermanence would be great, but impermanence would def be out of scope for this RFC. |
I can help/be the new author of this for now if nobody else steps up, I still think this is a great idea. |
Disko in the meantime also added support for updating some aspects of the disk configuration in an existing system. Systemd-repart supports some stuff as well but is still more limited. |
If you're still up for it and have the bandwidth to progress the RFC, please feel free to undraft, open for nominations and get things moving. I'm sure a lot of people, like myself, would like to see this materialise. |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/rfcsc-meeting-2024-09-02/51514/1 |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/rfcsc-meeting-2024-09-16/52224/1 |
# Motivation | ||
[motivation]: #motivation | ||
|
||
Why are we doing this? What use cases does it support? What is the expected |
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.
What is the motivation for this RFC? Don't we already have implementation? What are we trying to decide on?
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.
I'm aware of Disko, but I'm not aware of any official way to declare filesystems.
WIP, feel free to get involved.
@Lassulus @Mic92 As the biggest contributors to Disko, your ideas & contributions would be very welcome. I feel like declarative filesystem layouts could massively simplify one of the biggest, riskiest, and most long-standing complexities of installing any Linux distro.