Varnish VCL Syntax Highlighting in Sublime Text

Author: | 2 Comments
I love the Sublime Text editor on Mac. It's super simple & lightweight, it's got plenty of shortcuts and once you get the hang of it -- it's a real power horse. Since I do quite a bit work in Varnish, writing VCLs and custom rules, syntax highlighting is

Varnish VCL: Case Insensitive Regex

Author: | No comments
By default, a regex match in Varnish happens case sensitive. If you want to use a case insensitive check, you can use the (?i) flag. This is a normal, case sensitive regex check: if ( ~ "^domain.(be|nl|com)$") { ... } To make the same check case insensitive, add the

Varnish Cache 3.0 Is End Of Life

Author: | No comments
A year after the release of Varnish 4, version 3.0 has been declared end-of-life.

Running Varnish 4.x on systemd

Author: | 1 Comment
If you're thinking about running Varnish 4.x on a systemd system, you may be surprised that many of your "older" configs no longer work.

Debug Varnish 4.x on systemd That Fails to Start

Author: | 2 Comments
So you're stuck in systemctl start varnish, now what?

Explicitly Approving (Whitelisting) Cookies in Varnish With Libvmod-Cookie

Author: | No comments
In all my previous Varnish 3.x configs, I've always used blacklisting as the way of handling Cookies. You explicitly tell which cookies you want to remove in vcl_recv, all others remain. But just as security measures, whitelisting is always better than blacklisting.

Varnish FetchError http first read error: -1 11 (Resource temporarily unavailable)

Author: | 3 Comments
Just like the Straight insufficient bytes error, this is another error you can see in your varnishlogs.

Roundup: Belgacom Hack, Defcon, Varnish, HTTPs, Chrome and PHP

Author: | No comments
Here's what happend last week on this blog, just in case you missed it. The Real Cost of the ā€œSā€ in HTTPS The Pirate Bay calls it quits Generate PHP core dumps on segfaults in PHP-FPM Varnish tip: see which cookies are being stripped in your VCL Chrome To

Reload Varnish VCL without losing cache data

Author: | No comments
You can reload the Varnish VCL configuration without actually restarting Varnish. A restart would stop the varnishd process and start it anew, clearing all the cache it has built up in the meantime. But you can also reload the varnish configurations, to load your new VCL without losing the

Combine Apache’s HTTP authentication with X-Forwarded-For IP whitelisting in Varnish

Author: | No comments
Such a long title for a post. If you want to protect a page or an entire website with HTTP authentication, but also want to whitelist a few fixed IPs (for instance: office or VPN IPs), you can combine both authentication mechanismes in Apache via .htaccess files.