From mboxrd@z Thu Jan 1 00:00:00 1970 From: Leo Famulari Subject: Re: [PATCH 1/2] doc: Symlink daemon start-up files. Date: Fri, 18 Nov 2016 15:31:24 -0500 Message-ID: <20161118203124.GA27280@jasmine> References: <1479466834-3508-1-git-send-email-h.goebel@crazy-compilers.com> <1479466834-3508-2-git-send-email-h.goebel@crazy-compilers.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:54267) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1c7pop-0001lu-Aw for guix-devel@gnu.org; Fri, 18 Nov 2016 15:31:32 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1c7pom-0003aj-6h for guix-devel@gnu.org; Fri, 18 Nov 2016 15:31:31 -0500 Received: from out2-smtp.messagingengine.com ([66.111.4.26]:35819) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1c7pom-0003aX-2D for guix-devel@gnu.org; Fri, 18 Nov 2016 15:31:28 -0500 Content-Disposition: inline In-Reply-To: <1479466834-3508-2-git-send-email-h.goebel@crazy-compilers.com> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Hartmut Goebel Cc: guix-devel@gnu.org On Fri, Nov 18, 2016 at 12:00:33PM +0100, Hartmut Goebel wrote: > This patch ensures that always the current profile's daemon will be used. > > The .service file contains the path to the guix-daemon within the store. Thus > when copying the file, it will point to the very version of guix-daemon used > at the time of copying – even after system upgrade or when this version has > been garbage collected from the store. I'd argue it should point to /var/guix/profiles/per-user/root/... but I don't really care one way or the other since I often write my own systemd unit files since they are usually trivial. Actually, it looks like guix-daemon.service.in builds the path from @bindir@, so in my unprivileged Git work tree, guix-daemon.service execs /usr/local/bin/guix-daemon. This service wouldn't work for me since guix-daemon is not there. > * doc/guix.texi (Binary Installation): Change example code for installing > the systemd and Upstart files to use symbolic links instead of copying > the files. > --- > doc/guix.texi | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/doc/guix.texi b/doc/guix.texi > index a3eba58..92d7ee8 100644 > --- a/doc/guix.texi > +++ b/doc/guix.texi > @@ -453,7 +453,7 @@ If your host distro uses the systemd init system, this can be achieved > with these commands: > > @example > -# cp ~root/.guix-profile/lib/systemd/system/guix-daemon.service \ > +# ln -s ~root/.guix-profile/lib/systemd/system/guix-daemon.service \ > /etc/systemd/system/ > # systemctl start guix-daemon && systemctl enable guix-daemon Does systemd allow symlinked unit files (aka service definitions)? I read this old discussion that says "No" [0] but it could have changed by now [1]. [0] https://bugzilla.redhat.com/show_bug.cgi?id=955379 [1] https://bugzilla.redhat.com/show_bug.cgi?id=1014311 > @end example > @@ -461,7 +461,7 @@ with these commands: > If your host distro uses the Upstart init system: > > @example > -# cp ~root/.guix-profile/lib/upstart/system/guix-daemon.conf /etc/init/ > +# ln -s ~root/.guix-profile/lib/upstart/system/guix-daemon.conf /etc/init/ > # start guix-daemon I don't know anything about upstart, so no comments here.