aboutsummaryrefslogtreecommitdiff
path: root/gnu/system/shadow.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2013-12-07 15:01:40 +0100
committerLudovic Courtès <ludo@gnu.org>2013-12-07 15:01:40 +0100
commit18fb40e414d000b5f342b009a9fbfdc69afb704e (patch)
tree9776d038ebab98ac4f950f2a53cc7c9cbbecbb46 /gnu/system/shadow.scm
parent25ed6edb6c17e0c7817cb8b29a549b10c8654eba (diff)
downloadgnu-guix-18fb40e414d000b5f342b009a9fbfdc69afb704e.tar
gnu-guix-18fb40e414d000b5f342b009a9fbfdc69afb704e.tar.gz
gnu: dmd: Add 'user-accounts' and 'user-groups' fields to <service>.
* gnu/system/shadow.scm (guix-build-accounts): Move to... * gnu/system/dmd.scm (guix-build-accounts): ... here. (<service>)[user-accounts, user-groups]: New fields. (guix-service): New #:build-user-id and #:build-accounts parameters. Use 'guix-build-accounts' and set the 'user-accounts' and 'user-groups' fields accordingly. * gnu/system/vm.scm (system-qemu-image): Remove use of 'guix-build-accounts'. Augment ACCOUNTS and GROUPS from what SERVICES demand.
Diffstat (limited to 'gnu/system/shadow.scm')
-rw-r--r--gnu/system/shadow.scm23
1 files changed, 0 insertions, 23 deletions
diff --git a/gnu/system/shadow.scm b/gnu/system/shadow.scm
index 654fd4d55b..2cc0b89162 100644
--- a/gnu/system/shadow.scm
+++ b/gnu/system/shadow.scm
@@ -24,9 +24,7 @@
#:use-module ((gnu packages system)
#:select (shadow))
#:use-module (srfi srfi-1)
- #:use-module (srfi srfi-26)
#:use-module (ice-9 match)
- #:use-module (ice-9 format)
#:export (user-account
user-account?
user-account-name
@@ -117,25 +115,4 @@ file."
(text-file (if shadow? "shadow" "passwd") contents))
-(define* (guix-build-accounts count #:key
- (first-uid 30001)
- (gid 30000)
- (shadow shadow))
- "Return a list of COUNT user accounts for Guix build users, with UIDs
-starting at FIRST-UID, and under GID."
- (mlet* %store-monad ((gid* -> gid)
- (no-login (package-file shadow "sbin/nologin")))
- (return (unfold (cut > <> count)
- (lambda (n)
- (user-account
- (name (format #f "guixbuilder~2,'0d" n))
- (password "!")
- (uid (+ first-uid n -1))
- (gid gid*)
- (comment (format #f "Guix Build User ~2d" n))
- (home-directory "/var/empty")
- (shell no-login)))
- 1+
- 1))))
-
;;; shadow.scm ends here