[Nix-dev] Copy a closure to machine with no Nix installed on it

Tomasz Czyż tomasz.czyz at gmail.com
Thu Mar 2 17:59:28 CET 2017


Also, somebody mentioned https://github.com/matthewbauer/nix-bundle
recently which is nice way to distribute some software to non nix
environments.

2017-03-02 16:49 GMT+00:00 Bjørn Forsman <bjorn.forsman at gmail.com>:

> On 2 March 2017 at 17:38, Volth <volth at volth.com> wrote:
> > Hello
> >
> > What is a good way to copy a closure to a Linux machine where Nix is
> > not installed (and it is tricky to install: 1. there is only root
> > account and 2. there may be no Internet access) ?
> >
> > "nix-copy-closure" expects "nix-store" on the target machine.
> >
> > Would "nix-store" be a single executable with no dependencies, it
> > could be uploaded beforehand, but it has a lot of dependencies so its
> > uploading is also the task of uploading a closure to a machine without
> > Nix...
>
> Don't know how to do it without Nix, but Nix can be installed offline.
> Get the binary tarball for you system:
>
> http://nixos.org/releases/nix/nix-1.11.7/nix-1.11.7-x86_64-linux.tar.bz2
>
> Copy it to your target machine, unpack and run ./install from the
> extracted tree.
>
> That creates a single user install. It requires sudo to create the
> /nix directory, everything else is owned and run by your user. (There
> are ways to run nix from $HOME or wherever, I think "proot" is a good
> search word.)
>
> Once you have nix you have nix-copy-closure.
>
> Hope that helps.
>
> Best regards,
> Bjørn Forsman
> _______________________________________________
> nix-dev mailing list
> nix-dev at lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>



-- 
Tomasz Czyż
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.science.uu.nl/pipermail/nix-dev/attachments/20170302/206eb818/attachment-0001.html>


More information about the nix-dev mailing list