GNU bug report logs -
#38059
[PATCH 0/3] services: Add pagekite-service-type.
Previous Next
Reported by: "Alex Griffin" <a <at> ajgrf.com>
Date: Mon, 4 Nov 2019 14:45:02 UTC
Severity: normal
Tags: patch
Done: "Alex Griffin" <a <at> ajgrf.com>
Bug is archived. No further changes may be made.
Full log
Message #28 received at 38059 <at> debbugs.gnu.org (full text, mbox):
Hi,
"Alex Griffin" <a <at> ajgrf.com> skribis:
> From 46a5e48f5e89be4da3611bd11b55ed0e325c6538 Mon Sep 17 00:00:00 2001
> From: Alex Griffin <a <at> ajgrf.com>
> Date: Mon, 4 Nov 2019 19:29:24 -0600
> Subject: [PATCH 3/3] services: Add pagekite-service-type.
>
> * gnu/services/networking.scm (pagekite-service-type): New service type.
> (<pagekite-configuration>): New record type.
> (pagekite-shepherd-service): New procedure.
> * doc/guix.texi (Networking Services): Document it.
[...]
> +(define pagekite-configuration-file
> + (match-lambda
> + (($ <pagekite-configuration> package kitename kitesecret
> + frontend kites extra-file)
[...]
> +(define (pagekite-shepherd-service config)
> + (match config
> + (($ <pagekite-configuration> package kitename kitesecret
> + frontend kites extra-file)
I recommend using ‘match-record’ in these two cases since it matches
fields by name and is thus less error-prone.
> + (start #~(make-forkexec-constructor/container
Nice. :-)
Is there some meaningful test that could be written for this service? I
suppose it’d be hard to test without also running a relay. Anyway, if
you can think of a non-trivial test that could detect regressions,
you’re welcome to add it to (gnu tests …).
Otherwise LGTM!
Thanks,
Ludo’.
This bug report was last modified 5 years and 277 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.