all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Ludovic Courtès" <ludo@gnu.org>
To: Jonathan Brielmaier <jonathan.brielmaier@web.de>
Cc: 59515@debbugs.gnu.org
Subject: bug#59515: nginx: Fails to start on boot while upstream service is not yet running
Date: Sun, 27 Nov 2022 22:14:48 +0100	[thread overview]
Message-ID: <87a64c5cc7.fsf@gnu.org> (raw)
In-Reply-To: <ca94c57f-b01e-8201-da00-718991dda7f0@web.de> (Jonathan Brielmaier's message of "Fri, 25 Nov 2022 09:56:00 +0100")

Jonathan Brielmaier <jonathan.brielmaier@web.de> skribis:

> I added `(shepherd-requirement '(radicale))` to my nginx-configuration.
> Sadly the issue is not fixed, the situation is the same as before.
>
> I assume that radicale takes a fracture of a second to start. And nginx
> starts faster up. See this small experiment:

That looks like a bug in the radicale service: there’s no
synchronization upon startup:

--8<---------------cut here---------------start------------->8---
     (list (shepherd-service
            (provision '(radicale))
            (documentation "Run the radicale daemon.")
            (requirement '(networking))
            (start #~(make-forkexec-constructor
                      (list #$(file-append package "/bin/radicale")
                        "-C" #$config-file)
                      #:user "radicale"
                      #:group "radicale"))
            (stop #~(make-kill-destructor))))
--8<---------------cut here---------------end--------------->8---

It should wait for a PID file or be started as a systemd or inetd
service.  That way, we’d be sure that shepherd considers it started once
it’s really listening for input.  A quick grep in the source suggests it
creates a PID file somewhere.

HTH!

Ludo’.




  reply	other threads:[~2022-11-27 21:15 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-23 15:34 bug#59515: nginx: Fails to start on boot while upstream service is not yet running Jonathan Brielmaier
2022-11-23 17:35 ` mirai
2022-11-25  8:56 ` Jonathan Brielmaier
2022-11-27 21:14   ` Ludovic Courtès [this message]
2023-01-02 17:09     ` Jonathan Brielmaier
2023-03-21 23:02 ` Jonathan Brielmaier

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

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

  git send-email \
    --in-reply-to=87a64c5cc7.fsf@gnu.org \
    --to=ludo@gnu.org \
    --cc=59515@debbugs.gnu.org \
    --cc=jonathan.brielmaier@web.de \
    /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.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.