Added the check.

About multiple hostnames: we could have that in the (CacheManager) layer on top of the caching proxy implementations. The CacheManager would just call the `purge($url)` multiple times with absolute URLs. This has the advantage of keeping the Varnish class cleaner.