summary refs log tree commit diff
path: root/gnu/build/shepherd.scm
diff options
context:
space:
mode:
authorMarius Bakke <marius@gnu.org>2022-09-08 21:12:52 +0200
committerMarius Bakke <marius@gnu.org>2022-09-08 21:12:52 +0200
commit884548b476f2ee27c01cb0c9ad93c0cf9d33fa5e (patch)
tree20650b3917b1292470ecc4ded13fbb04e5dbfa6d /gnu/build/shepherd.scm
parent0e305798454c558ab6e722cf66ba351c326a1a8d (diff)
parentfa894b3f4db835bd0bb52b32c7ec412e72b7e03a (diff)
downloadguix-884548b476f2ee27c01cb0c9ad93c0cf9d33fa5e.tar.gz
Merge branch 'staging' into core-updates
Diffstat (limited to 'gnu/build/shepherd.scm')
-rw-r--r--gnu/build/shepherd.scm3
1 files changed, 2 insertions, 1 deletions
diff --git a/gnu/build/shepherd.scm b/gnu/build/shepherd.scm
index f4caefce3c..9d9bfcfbc0 100644
--- a/gnu/build/shepherd.scm
+++ b/gnu/build/shepherd.scm
@@ -2,6 +2,7 @@
 ;;; Copyright © 2017, 2018, 2019, 2020, 2022 Ludovic Courtès <ludo@gnu.org>
 ;;; Copyright © 2020 Mathieu Othacehe <othacehe@gnu.org>
 ;;; Copyright © 2022 Leo Nikkilä <hello@lnikki.la>
+;;; Copyright © 2022 Arun Isaac <arunisaac@systemreboot.net>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -186,7 +187,7 @@ namespace, in addition to essential bind-mounts such /proc."
     (when log-file
       ;; Create LOG-FILE so we can map it in the container.
       (unless (file-exists? log-file)
-        (call-with-output-file log-file (const #t))
+        (close (open log-file (logior O_CREAT O_APPEND O_CLOEXEC) #o640))
         (when user
           (let ((pw (getpwnam user)))
             (chown log-file (passwd:uid pw) (passwd:gid pw))))))