mark: A photo of Mark kneeling on top of the Taal Volcano in the Philippines. It was a long hike. (0)
Mark Smith ([staff profile] mark) wrote in [site community profile] dw_dev 2013-02-01 11:26 pm (UTC)

varnishd (varnish-3.0.2 revision cbf1284)

EXCITEMENT. Added to the config:

    # gzip outgoing HTML/CSS/JS.
    if (req.url ~ "\.(html|css|js)(\?v=\d+)?$" &&
            beresp.http.content-type ~ "text") {
        set beresp.do_gzip = true;
    }

So far, it looks good. I see static content is responding to gzip requests, and varnishd's CPU is not crazy higher. It might be up a bit, but it still gets lost in the noise of the Perlbals.

I'm going to be offline for the next ~24 hours. If something is wrong, you can revert the above section from lb02's /etc/varnish/default.vcl and run /root/bin/reload-varnish-config on that machine. (I'm quite sure you know all that, but meh.)

Edit: This doesn't really compress most of our web output. Just the static files. It'd be nice to figure out if we can compress our HTML output, although pattern-matching all of that might be interesting.

We should probably make it a compression-opt-out instead of choosing what to compress. That way we just have to match the media URLs and also PNG, GIF, JPG, etc.

Post a comment in response:

If you don't have an account you can create one now.
HTML doesn't work in the subject.
More info about formatting

If you are unable to use this captcha for any reason, please contact us by email at support@dreamwidth.org