Subject: Re: [bug#40993] cuirass: Add build products download support.

From: Ludovic Courtès <[email-masked]>
Date: Fri, 01 May 2020 23:11:38 +0200

Hi,

Danny Milosavljevic <[email-masked]> skribis:

> Though I agree using sendfile would be much better, especially since the user
> can download 800 MB image files there.
>
> The guile (web server) module allows passing a procedure as the #:body, but
> then it makes a bytevector out of the result and hard-codes the content-type :P.
>
> Eventually (web server http) http-write is reached, which only supports encoding
> bytevectors and #f, that's it.  No files.
>
> So we'd have to overwrite http-write.

See how ‘guix publish’ uses ‘sendfile’ for nars.  It’s hacky because it
works around <https://issues.guix.gnu.org/issue/21093>.

Ludo’.