[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] gnu: Use a directory owned by ntpd user for drift file.
From: |
Vincent Legoll |
Subject: |
Re: [PATCH] gnu: Use a directory owned by ntpd user for drift file. |
Date: |
Thu, 8 Sep 2016 08:57:57 +0200 |
Hello,
> +(define (ntp-service-activation config)
> + "Return the activation gexp for config"
> + #~(begin
> + (use-modules (guix build utils))
> +
> + (define %user
> + (getpw "ntpd"))
> +
> + (let ((directory "/var/run/ntpd"))
> + (mkdir-p directory)
> + (chown directory (passwd:uid %user) (passwd:gid %user)))))
> +
Excuse my scheme-newbie questions, but
- why did you use %user (I thought %s were for kind of global vars) ?
- why did you use define and not put it in the let just below ? Idon't see
it being used elsewhere...
--
Vincent Legoll