Skip to content

Commit

Permalink
doc: clarify building-nixos CD/DVD instructions
Browse files Browse the repository at this point in the history
This change updates the instructions for building a NixOS ISO so that it's clear how to do it.

Previously, the instructions stated to set NIXOS_CONFIG prior to running `nix-build`, yet the example provided by-passed NIXOS_CONFIG anyway. But the *really* important missing piece is the need for nixos/default.nix. See #21840.

This change removes the NIXOS_CONFIG verbiage, and adds steps to clone nixpkgs and (most importantly) cd'ing into nixpkgs/nixos. That way, the reader may think: *Oh, so I need a default.nix and a configuration.nix. Ahhh, OK.*

I purposely added the redundant default.nix argument.
  • Loading branch information
emmanuelrosa authored and grahamc committed Jun 3, 2017
1 parent 4576e8d commit 4bee34d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions nixos/doc/manual/development/building-nixos.xml
Expand Up @@ -12,12 +12,12 @@ your <filename>configuration.nix</filename> to configure the system that
would be installed on the CD.</para>

<para>Default CD/DVD configurations are available
inside <filename>nixos/modules/installer/cd-dvd</filename>. To build them
you have to set <envar>NIXOS_CONFIG</envar> before
running <command>nix-build</command> to build the ISO.
inside <filename>nixos/modules/installer/cd-dvd</filename>.

<screen>
$ nix-build -A config.system.build.isoImage -I nixos-config=modules/installer/cd-dvd/installation-cd-minimal.nix</screen>
$ git clone https://github.com/NixOS/nixpkgs.git
$ cd nixpkgs/nixos
$ nix-build -A config.system.build.isoImage -I nixos-config=modules/installer/cd-dvd/installation-cd-minimal.nix default.nix</screen>

</para>

Expand Down

0 comments on commit 4bee34d

Please sign in to comment.