diff options
| author | Mario Daniel Ruiz Saavedra <desiderantes@rocketmail.com> | 2015-11-26 11:07:51 -0500 |
|---|---|---|
| committer | Ludovic Courtès <ludo@gnu.org> | 2015-11-26 23:21:09 +0100 |
| commit | ad227484c3e1dc85488be76a23128e77ad0b33ff (patch) | |
| tree | 722162f419a9f83350d74824e01029fe1426f0fe | |
| parent | 5432734b00ae14c3a93af358fc7bbf80e3db5ee8 (diff) | |
Add 'guix-daemon.conf' job for Upstart.
* etc/guix-daemon.conf.in: New file.
* daemon.am (CLEANFILES): Add etc/guix-daemon.conf.
(upstartjobdir, nodist_upstartjob_DATA): New variables.
(EXTRA_DIST): Add etc/guix-daemon.conf.in.
* doc/guix.texi (Binary Installation, Build Environment Setup): Mention
'guix-daemon.conf'.
Signed-off-by: Mario Daniel Ruiz Saavedra <desiderantes@rocketmail.com>
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | daemon.am | 16 | ||||
| -rw-r--r-- | doc/guix.texi | 9 | ||||
| -rw-r--r-- | etc/guix-daemon.conf.in | 12 |
4 files changed, 35 insertions, 3 deletions
diff --git a/.gitignore b/.gitignore index 6e8bfaca95d..412d09ca11c 100644 --- a/.gitignore +++ b/.gitignore | |||
| @@ -125,6 +125,7 @@ GTAGS | |||
| 125 | /doc/os-config-desktop.texi | 125 | /doc/os-config-desktop.texi |
| 126 | /doc/*.1 | 126 | /doc/*.1 |
| 127 | /etc/guix-daemon.service | 127 | /etc/guix-daemon.service |
| 128 | /etc/guix-daemon.conf | ||
| 128 | /doc/images/bootstrap-graph.pdf | 129 | /doc/images/bootstrap-graph.pdf |
| 129 | /doc/images/coreutils-bag-graph.png | 130 | /doc/images/coreutils-bag-graph.png |
| 130 | /doc/images/coreutils-graph.png | 131 | /doc/images/coreutils-graph.png |
| @@ -21,7 +21,7 @@ | |||
| 21 | # | 21 | # |
| 22 | 22 | ||
| 23 | BUILT_SOURCES += nix/libstore/schema.sql.hh | 23 | BUILT_SOURCES += nix/libstore/schema.sql.hh |
| 24 | CLEANFILES += $(BUILT_SOURCES) etc/guix-daemon.service | 24 | CLEANFILES += $(BUILT_SOURCES) etc/guix-daemon.service etc/guix-daemon.conf |
| 25 | 25 | ||
| 26 | noinst_LIBRARIES = libformat.a libutil.a libstore.a | 26 | noinst_LIBRARIES = libformat.a libutil.a libstore.a |
| 27 | 27 | ||
| @@ -191,11 +191,23 @@ etc/guix-daemon.service: etc/guix-daemon.service.in \ | |||
| 191 | "$(srcdir)/etc/guix-daemon.service.in" > "$@.tmp" | 191 | "$(srcdir)/etc/guix-daemon.service.in" > "$@.tmp" |
| 192 | mv "$@.tmp" "$@" | 192 | mv "$@.tmp" "$@" |
| 193 | 193 | ||
| 194 | # The '.conf' job for Upstart. | ||
| 195 | upstartjobdir = $(libdir)/upstart/system | ||
| 196 | nodist_upstartjob_DATA = etc/guix-daemon.conf | ||
| 197 | |||
| 198 | etc/guix-daemon.conf: etc/guix-daemon.conf.in \ | ||
| 199 | $(top_builddir)/config.status | ||
| 200 | $(MKDIR_P) "`dirname "$@"`" | ||
| 201 | $(SED) -e 's|@''bindir''@|$(bindir)|' < \ | ||
| 202 | "$(srcdir)/etc/guix-daemon.conf.in" > "$@.tmp" | ||
| 203 | mv "$@.tmp" "$@" | ||
| 204 | |||
| 194 | EXTRA_DIST += \ | 205 | EXTRA_DIST += \ |
| 195 | nix/libstore/schema.sql \ | 206 | nix/libstore/schema.sql \ |
| 196 | nix/AUTHORS \ | 207 | nix/AUTHORS \ |
| 197 | nix/COPYING \ | 208 | nix/COPYING \ |
| 198 | etc/guix-daemon.service.in | 209 | etc/guix-daemon.service.in \ |
| 210 | etc/guix-daemon.conf.in | ||
| 199 | 211 | ||
| 200 | AM_TESTS_ENVIRONMENT += \ | 212 | AM_TESTS_ENVIRONMENT += \ |
| 201 | top_builddir="$(abs_top_builddir)" | 213 | top_builddir="$(abs_top_builddir)" |
diff --git a/doc/guix.texi b/doc/guix.texi index 8ecb7ccc178..b4044531ede 100644 --- a/doc/guix.texi +++ b/doc/guix.texi | |||
| @@ -366,6 +366,10 @@ On hosts using the systemd init system, drop | |||
| 366 | @file{~root/.guix-profile/lib/systemd/system/guix-daemon.service} in | 366 | @file{~root/.guix-profile/lib/systemd/system/guix-daemon.service} in |
| 367 | @file{/etc/systemd/system}. | 367 | @file{/etc/systemd/system}. |
| 368 | 368 | ||
| 369 | Likewise, on hosts using the Upstart init system, drop | ||
| 370 | @file{~root/.guix-profile/lib/upstart/system/guix-daemon.conf} in | ||
| 371 | @file{/etc/init}. | ||
| 372 | |||
| 369 | @item | 373 | @item |
| 370 | Make the @command{guix} command available to other users on the machine, | 374 | Make the @command{guix} command available to other users on the machine, |
| 371 | for instance with: | 375 | for instance with: |
| @@ -554,7 +558,10 @@ parallel, as specified by the @option{--max-jobs} option | |||
| 554 | following command@footnote{If your machine uses the systemd init system, | 558 | following command@footnote{If your machine uses the systemd init system, |
| 555 | dropping the @file{@var{prefix}/lib/systemd/system/guix-daemon.service} | 559 | dropping the @file{@var{prefix}/lib/systemd/system/guix-daemon.service} |
| 556 | file in @file{/etc/systemd/system} will ensure that | 560 | file in @file{/etc/systemd/system} will ensure that |
| 557 | @command{guix-daemon} is automatically started.}: | 561 | @command{guix-daemon} is automatically started. Similarly, if your |
| 562 | machine uses the Upstart init system, drop the | ||
| 563 | @file{@var{prefix}/lib/upstart/system/guix-daemon.conf} | ||
| 564 | file in @file{/etc/init}.}: | ||
| 558 | 565 | ||
| 559 | @example | 566 | @example |
| 560 | # guix-daemon --build-users-group=guixbuild | 567 | # guix-daemon --build-users-group=guixbuild |
diff --git a/etc/guix-daemon.conf.in b/etc/guix-daemon.conf.in new file mode 100644 index 00000000000..8f833cb6930 --- /dev/null +++ b/etc/guix-daemon.conf.in | |||
| @@ -0,0 +1,12 @@ | |||
| 1 | # This is a "job" for the Upstart init system to launch 'guix-daemon'. | ||
| 2 | # Drop it in /etc/init to have 'guix-daemon' automatically started. | ||
| 3 | |||
| 4 | description "Build daemon for GNU Guix" | ||
| 5 | |||
| 6 | start on runlevel [2345] | ||
| 7 | |||
| 8 | stop on runlevel [016] | ||
| 9 | |||
| 10 | task | ||
| 11 | |||
| 12 | exec @bindir@/guix-daemon --build-users-group=guixbuild | ||
