unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
From: Robert Vollmert <rob@vllmrt.net>
To: Reza Alizadeh Majd <r.majd@pantherx.org>
Cc: help-guix@gnu.org
Subject: Re: extending a service to create an extra directory
Date: Sat, 20 Jul 2019 09:57:31 +0200	[thread overview]
Message-ID: <D0322F41-EE8E-4555-9B10-01486911CFA0@vllmrt.net> (raw)
In-Reply-To: <ad4784ba-560d-4234-8b4b-3b104e141ea2@www.fastmail.com>

On 20. Jul 2019, at 08:18, Reza Alizadeh Majd <r.majd@pantherx.org> wrote:
> On Thu, Jul 18, 2019, at 6:30 PM, Robert Vollmert wrote:
>> 
>> I’m trying to set up nginx properly, and my config involves a
>> cache directory, say /var/nginx/cache. To encode this properly,
>> I’d like to to make my nginx service create that directory
>> with appropriate user and rights on service activation. I can’t
>> figure out how to do that without assembling a whole new service
>> out of the parts of the existing nginx-service. There must be a
>> more reasonable way?
> 
> It seems that proper way to do this is to define a new service for
> activating cache directory. since it was defined previously on Guix
> CI server: 
> 
> https://git.savannah.gnu.org/cgit/guix/maintenance.git/tree/hydra/modules/sysadmin/services.scm#n221

Thanks for the pointer. Even apart from my concrete issue here, reading
a complete worked config is very helpful — would be great if the manual
contained such (or a link to some examples).

The particular example of using a simple-service of activation-service-type
is also helpful; it will work for me for now.

It bothers me a bit that this activation action isn’t “part” of the nginx
services activation. I could see nginx activation fail if the cache directory
service didn’t happen to run first. Might this be solved be by adding a
shepherd “requirement”?

Cheers
Robert

      reply	other threads:[~2019-07-20  7:57 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-18 13:47 extending a service to create an extra directory Robert Vollmert
2019-07-20  6:18 ` Reza Alizadeh Majd
2019-07-20  7:57   ` Robert Vollmert [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=D0322F41-EE8E-4555-9B10-01486911CFA0@vllmrt.net \
    --to=rob@vllmrt.net \
    --cc=help-guix@gnu.org \
    --cc=r.majd@pantherx.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).