From ee2691fa33f117bcf51b148b81bb8bc4e7b13a58 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Mon, 3 Jun 2019 22:27:25 +0200 Subject: services: guix-publish: Allow for multi-compression. This is a followup to b8fa86adfc01205f1d942af8cb57515eb3726c52. * guix/deprecation.scm (warn-about-deprecation): Make public. * gnu/services/base.scm ()[compression]: New field. [compression-level]: Default to #f. Add '%' to getter name. (guix-publish-configuration-compression-level): Define as deprecated. (default-compression): New procedure. (guix-publish-shepherd-service)[config->compression-options]: New procedure. Use 'match-record' instead of 'match'. * doc/guix.texi (Base Services): Remove 'compression-level' and document 'compression'. --- doc/guix.texi | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) (limited to 'doc/guix.texi') diff --git a/doc/guix.texi b/doc/guix.texi index c01eb3a656..a8f3a5ad27 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -12232,10 +12232,19 @@ The TCP port to listen for connections. The host (and thus, network interface) to listen to. Use @code{"0.0.0.0"} to listen on all the network interfaces. -@item @code{compression-level} (default: @code{3}) -The gzip compression level at which substitutes are compressed. Use -@code{0} to disable compression altogether, and @code{9} to get the best -compression ratio at the expense of increased CPU usage. +@item @code{compression} (default: @code{'(("gzip" 3))}) +This is a list of compression method/level tuple used when compressing +substitutes. For example, to compress all substitutes with @emph{both} lzip +at level 7 and gzip at level 9, write: + +@example +'(("lzip" 7) ("gzip" 9)) +@end example + +Level 9 achieves the best compression ratio at the expense of increased CPU +usage, whereas level 1 achieves fast compression. + +An empty list disables compression altogether. @item @code{nar-path} (default: @code{"nar"}) The URL path at which ``nars'' can be fetched. @xref{Invoking guix -- cgit v1.2.3