NixOS / nixpkgs

Nix Packages collection & NixOS
MIT License
17.28k stars 13.53k forks source link

rootfs tarball #19522

Open NeQuissimus opened 7 years ago

NeQuissimus commented 7 years ago

I would like to build a NixOS Dockerfile from scratch. For this, it is easiest to have a rootfs.tar.xz. Running something like NIXOS_CONFIG=/home/nequi/dev/DevSetup/docker/configuration.nix nix-build -A config.system.build.tarball --argstr system x86_64-linux will give me a tarball, which I assume to be the rootfs under a different name.

This tarball does not quite work for me but that is not what this is about.

Is there a place on Hydra that keeps the tarballs used to create the ISOs for official releases? I tried looking through some evaluations but could not find anything.

dezgeg commented 7 years ago

ISO creation doesn't use an intermediate tarball. It's built from the system closure (config.system.build.toplevel) directly.

NeQuissimus commented 7 years ago

Oh, I see.

So the output of nixos/release.nix -> makeSystemTarball is not actually generated?

dezgeg commented 7 years ago

Oh, indeed we actually generate those: http://hydra.nixos.org/build/42024611. But it is not used by the ISO image build, it's something separate (and quite likely not covered by any NixOS tests).

NeQuissimus commented 7 years ago

Ah, this is what I was looking for :D Except, the file seems to get deleted :(

florianjacob commented 7 years ago

Yeah, this tarball seems to vanish instantly after generation. ☹️ I used the „reproduce this build“ link and compiled it myself, problem is the resulting tarball seems to only contain /nix/store and some mountpoints but no something like /etc/os-release (or any /etc at all) so that I could execute it with e.g. systemd-nspawn.

globin commented 7 years ago

nixos/hydra#321

mmahut commented 5 years ago

Are there any updates to this issue, please?

stale[bot] commented 4 years ago

Thank you for your contributions.

This has been automatically marked as stale because it has had no activity for 180 days.

If this is still important to you, we ask that you leave a comment below. Your comment can be as simple as "still important to me". This lets people see that at least one person still cares about this. Someone will have to do this at most twice a year if there is no other activity.

Here are suggestions that might help resolve this more quickly:

  1. Search for maintainers and people that previously touched the related code and @ mention them in a comment.
  2. Ask on the NixOS Discourse.
  3. Ask on the #nixos channel on irc.freenode.net.
cedws commented 4 years ago

I'm still interested in this. My use case for this is that I want to bootstrap a minimal image which is 'ready to go'. Kind of like how you can with debootstrap. I realise I could use something like Packer to run the installation ISO but I'm not too keen on this.

stale[bot] commented 3 years ago

I marked this as stale due to inactivity. → More info