From fdaacbad85a23f89db9431477684fb1333de03f3 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Mon, 10 Nov 2014 23:23:32 +0100 Subject: services: Add 'auto-start?' field to . * gnu/services.scm ()[auto-start?]: New field. * gnu/services/dmd.scm (dmd-configuration-file): Honor it. * gnu/system/install.scm (cow-store-service): Add 'auto-start?' field. --- gnu/services.scm | 3 +++ gnu/services/dmd.scm | 4 +++- gnu/system/install.scm | 4 ++++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/gnu/services.scm b/gnu/services.scm index 37ecc019ec..43e51b998c 100644 --- a/gnu/services.scm +++ b/gnu/services.scm @@ -27,6 +27,7 @@ service-respawn? service-start service-stop + service-auto-start? service-activate service-user-accounts service-user-groups @@ -51,6 +52,8 @@ (start service-start) ; g-expression (procedure) (stop service-stop ; g-expression (procedure) (default #~(const #f))) + (auto-start? service-auto-start? ; Boolean + (default #t)) (user-accounts service-user-accounts ; list of (default '())) (user-groups service-user-groups ; list of diff --git a/gnu/services/dmd.scm b/gnu/services/dmd.scm index 59c2373779..35b6b384c1 100644 --- a/gnu/services/dmd.scm +++ b/gnu/services/dmd.scm @@ -68,7 +68,9 @@ (setenv "PATH" "/run/current-system/profile/bin") (format #t "starting services...~%") - (for-each start '#$(append-map service-provision services)))) + (for-each start + '#$(append-map service-provision + (filter service-auto-start? services))))) (gexp->file "dmd.conf" config))) diff --git a/gnu/system/install.scm b/gnu/system/install.scm index 6b3aa6cbf2..961361b937 100644 --- a/gnu/system/install.scm +++ b/gnu/system/install.scm @@ -102,6 +102,10 @@ the user's target storage device rather than on the RAM disk." (documentation "Make the store copy-on-write, with writes going to \ the given target.") + + ;; This is meant to be explicitly started by the user. + (auto-start? #f) + (start #~(case-lambda ((target) #$(make-cow-store #~target) -- cgit v1.2.3