[Nix-dev] bootstrap of NixOS

Patrick Wheeler patrick.john.wheeler at gmail.com
Thu Dec 26 21:42:40 CET 2013


If you are trying to learn the operating system specific features then you
will need to instal nixos, however you can learn about nixpkgs with out
installing the nixos operating system.  The nixpkgs package system installs
on ubuntu and most other distributions and operates cleanly
and orthogonally to any other package system present.  This would allow you
to learn the terminal commands and experiment with your own nix expressions
with out having to install nixos.  nixpkgs does not spread files through
out the file system like most package systems so a tool like debootstrap
may not be needed if you want to try out nixpkgs.

Typically this installs nix and nix/store folder at the root directory so
you would need to have the correct permissions for installation.

> I'd like start to learn and experiment with NixOS, in a virtualized
environment.

nixops makes it easy to set up a nixos instance in amazon's cloud, then
when you are not experimenting with it you can just halt it so changes do
not accumulate.  I also have install nixos with vmware to help myself learn
and this seem to work well.

>  Is there some tool like debootstrap for NixOS?

Petr,  the nix user manual has instructions to install the store in an
arbitrary location with `--with-store-dir=path` and the install location
can be changed with `--prefix=prefix` when using bootstrap.sh and building
from source.

http://nixos.org/nix/manual/#idp24488432

This would allow you to install nix in a arbitrary location.  The large
downside is that this is currently incompatible with taking advantage of
the pre complied binaries so you would have to compile everything from
scratch. If possible I would suggest letting nix install the store in the
default location: /nix/store.

If I was not clear or need some additional questions answer please ask I
will do my best to answer them.

Patrick


On Mon, Dec 23, 2013 at 11:47 AM, Petr Pudlák <pudlak at google.com> wrote:

> Hi,
>
> I'm looking for something that could be automated. Some kind of a
> self-contained script that automatically prepares a minimal NixOS
> installation. Eventually I'd like to create OS installation scripts [1] for
> Ganeti cluster management software [2].
>
> [1] http://docs.ganeti.org/ganeti/current/man/ganeti-os-interface.html
> [2] https://code.google.com/p/ganeti/
>
>   Thanks,
>   Petr
>
>
> On Mon, Dec 23, 2013 at 3:23 PM, Thomas Bereknyei <tomberek at gmail.com>wrote:
>
>> Would a LiveCD work for you? There a some available at
>> http://nixos.org/nixos/download.html as well as some virtualbox
>> appliances.
>>
>> On Sat, Dec 21, 2013 at 3:39 PM, Petr Pudlák <pudlak at google.com> wrote:
>> > Hi,
>> >
>> > I'd like start to learn and experiment with NixOS, in a virtualized
>> > environment. Is there some tool like debootstrap for NixOS? Some kind
>> of a
>> > minimalistic script/program that downloads and unpacks the bare
>> essentials
>> > of NixOS, allowing it to be run in a chroot or a VM? I tried to search,
>> but
>> > didn't find anything.
>> >
>> >   Thank you,
>> >   Petr
>> >
>> > _______________________________________________
>> > nix-dev mailing list
>> > nix-dev at lists.science.uu.nl
>> > http://lists.science.uu.nl/mailman/listinfo/nix-dev
>> >
>>
>
>
> _______________________________________________
> nix-dev mailing list
> nix-dev at lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>
>


-- 
Patrick Wheeler
Patrick.John.Wheeler at gmail.com
Patrick.J.Wheeler at rice.edu
Patrick.Wheeler at colorado.edu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.science.uu.nl/pipermail/nix-dev/attachments/20131226/f4ae8869/attachment.html 


More information about the nix-dev mailing list