GNU bug report logs - #29466
[PATCH] services: web: Add support for configuring the nginx server names hash.

Previous Next

Package: guix-patches;

Reported by: Christopher Baines <mail <at> cbaines.net>

Date: Mon, 27 Nov 2017 08:25:01 UTC

Severity: normal

Tags: patch

Done: Christopher Baines <mail <at> cbaines.net>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: ludo <at> gnu.org (Ludovic Courtès)
To: Christopher Baines <mail <at> cbaines.net>
Cc: 29466 <at> debbugs.gnu.org
Subject: [bug#29466] [PATCH] services: web: Add support for configuring the nginx server names hash.
Date: Mon, 27 Nov 2017 15:06:48 +0100
Hi!

Christopher Baines <mail <at> cbaines.net> skribis:

> The nginx service can fail to start if the server names hash bucket size is
> too small, which can happen on some systems, and when using QEMU, depending on
> the CPU.
>
> * gnu/services/web.scm (<nginx-configuration>): Add
>   server-names-hash-bucket-size and server-names-hash-bucket-max-size.
>   (default-nginx-config): Add support for the new hash bucket size parameters.
>   (nginx-service, nginx-activation): Pass the new hash bucket size parameters
>   through to the default-nginx-config procedure.
> * doc/guix.texi (Web Services): Document the new hash bucket size parameters.

LGTM!

However…

> -(define (default-nginx-config nginx log-directory run-directory server-list upstream-list)
> +(define (default-nginx-config nginx log-directory run-directory server-list
> +                              upstream-list server-names-hash-bucket-size
> +                              server-names-hash-bucket-max-size)

That’s too many positional parameters.  And should we use a gexp
compiler for <nginx-configuration> anyway?

>  (define nginx-shepherd-service
>    (match-lambda
>      (($ <nginx-configuration> nginx log-directory run-directory server-blocks
> -                              upstream-blocks file)
> +                              upstream-blocks server-names-hash-bucket-size
> +                              server-names-hash-bucket-max-size file)

Likewise, at this stage, we should probably use ‘match-record’ to avoid
mistakes.

Thanks,
Ludo’.




This bug report was last modified 7 years and 222 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.