Subject: [PATCH 7/8] gnu: Add perl-plack-middleware-deflater.

From: 宋文武 <[email-masked]>
Date: Sat, 6 Apr 2019 08:50:04 +0800

* gnu/packages/web.scm (perl-plack-middleware-deflater): New variable.
---
 gnu/packages/web.scm | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)

diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index e84b42358c..81c7c5bc88 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -3374,6 +3374,35 @@ application frameworks.  Plack is like Ruby's Rack or Python's Paste for
 WSGI.")
     (license l:perl-license)))
 
+(define-public perl-plack-middleware-deflater
+  (package
+    (name "perl-plack-middleware-deflater")
+    (version "0.12")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append
+             "mirror://cpan/authors/id/K/KA/KAZEBURO/"
+             "Plack-Middleware-Deflater-" version ".tar.gz"))
+       (sha256
+        (base32
+         "0xf2visi16hgwgyp9q0cjr10ikbn474hjia5mj8mb2scvbkrbni8"))))
+    (build-system perl-build-system)
+    (native-inputs
+     `(("perl-module-install" ,perl-module-install)
+       ("perl-test-requires" ,perl-test-requires)))
+    (propagated-inputs
+     `(("perl-plack" ,perl-plack)))
+    (home-page "https://metacpan.org/release/Plack-Middleware-Deflater")
+    (synopsis "Compress response body with Gzip or Deflate")
+    (description
+     "Plack::Middleware::Deflater is a middleware to encode your response body
+in gzip or deflate, based on \"Accept-Encoding\" HTTP request header.  It
+would save the bandwidth a little bit but should increase the Plack server
+load, so ideally you should handle this on the frontend reverse proxy
+servers.")
+    (license l:perl-license)))
+
 (define-public perl-plack-middleware-fixmissingbodyinredirect
   (package
     (name "perl-plack-middleware-fixmissingbodyinredirect")
-- 
2.19.2