[Nix-dev] disk setup for nixos installation

Domen Kožar domen at dev.si
Sat Aug 17 15:42:29 CEST 2013


I used something like this to generate an ISO image that would
self-install: http://paste.ofcode.org/K9Haex6MiBxygqJDFXkSL7




On Sat, Aug 17, 2013 at 3:22 PM, Tim Barbour <trb at categorical.net> wrote:

> I would like to be able to boot from nixos installation media, then do
> automated partitioning, LVM setup and filesystem creation, then let nixops
> do
> the rest. What is the best way to automate partitioning, LVM setup and
> filesystem creation ? I wrote a shell script to do this (just for one
> disk, so
> far) using parted etc., but it looks ugly, and I wonder if it would be
> better
> done using nix.
>
> Does nix / nixos provide any existing mechanisms for doing this ?
>
> I am an experienced functional programmer (Haskell, not nix), but I don't
> understand how to do IO in nix. Perhaps I should be modelling the disk
> setup
> as the building of some derivations, but such derivations would not
> produce a
> result in the nix store.  If I made them produce a result in the store,
> then
> the disk setup would be a side-effect, and not referentially transparent. I
> get the feeling that this is outside the scope of nix.
>
> Tim
> ---
> GPG public key available at:
>          http://phasechangeit.com/~trb/gpg-key  or
>          http://subkeys.pgp.net:11371
> _______________________________________________
> nix-dev mailing list
> nix-dev at lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.science.uu.nl/pipermail/nix-dev/attachments/20130817/0342de97/attachment-0001.html 


More information about the nix-dev mailing list