[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

02/03: install: Omit /root from the binary tarball.

From: Ludovic Courtès
Subject: 02/03: install: Omit /root from the binary tarball.
Date: Mon, 08 Jun 2015 21:32:13 +0000

civodul pushed a commit to branch master
in repository guix.

commit 7acd3439eab716882835228be16346c5d3b4df21
Author: Ludovic Courtès <address@hidden>
Date:   Mon Jun 8 23:25:51 2015 +0200

    install: Omit /root from the binary tarball.
    Suggested by Thomas Schwinge <address@hidden>.
    * gnu/system/install.scm (self-contained-tarball): Remove
      "/root/.guix-profile" from the 'tar' arguments.
    * doc/guix.texi (Binary Installation): Add a step to create
 doc/guix.texi          |   18 +++++++++++++-----
 gnu/system/install.scm |    7 ++++---
 2 files changed, 17 insertions(+), 8 deletions(-)

diff --git a/doc/guix.texi b/doc/guix.texi
index 85ccd40..a0f3443 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -284,18 +284,26 @@ As @code{root}, run:
 # tar xf address@hidden@var{system}.tar.xz
 @end example
-This creates @file{/gnu/store} (@pxref{The Store}), @file{/var/guix},
-and @file{/root/.guix-profile}.  @file{/root/.guix-profile} is a
-ready-to-use profile for @code{root} where Guix is installed.
+This creates @file{/gnu/store} (@pxref{The Store}) and @file{/var/guix}.
+The latter contains a ready-to-use profile for @code{root} (see next
 Do @emph{not} unpack the tarball on a working Guix system since that
 would overwrite its own essential files.
+Make @code{root}'s profile available under @file{~/.guix-profile}:
+# ln -sf /var/guix/profiles/per-user/root/guix-profile \
+         ~root/.guix-profile
address@hidden example
 Run the daemon:
-# /root/.guix-profile/bin/guix-daemon --build-users-group=guixbuild
+# ~root/.guix-profile/bin/guix-daemon --build-users-group=guixbuild
 @end example
@@ -313,7 +321,7 @@ To use substitutes from @code{} 
 authorize them:
-# guix archive --authorize < /root/.guix-profile/share/guix/
+# guix archive --authorize < ~root/.guix-profile/share/guix/
 @end example
 @end enumerate
diff --git a/gnu/system/install.scm b/gnu/system/install.scm
index cacd089..27d8ecd 100644
--- a/gnu/system/install.scm
+++ b/gnu/system/install.scm
@@ -73,11 +73,12 @@ under /root/.guix-profile where GUIX is installed."
             (zero? (system* "tar" "--xz" "--format=gnu"
                             "--owner=root:0" "--group=root:0"
                             "-cvf" #$output
-                            ;; Avoid adding /, /var, or /root to the tarball,
+                            ;; Avoid adding / and /var to the tarball,
                             ;; so that the ownership and permissions of those
                             ;; directories will not be overwritten when
-                            ;; extracting the archive.
-                            "./root/.guix-profile"
+                            ;; extracting the archive.  Do not include /root
+                            ;; because the root account might have a different
+                            ;; home directory.
                             (string-append "." (%store-directory)))))))

reply via email to

[Prev in Thread] Current Thread [Next in Thread]