timeout on varnish purger
This commit is contained in:
parent
ffc636515f
commit
ba3a61052f
1 changed files with 2 additions and 1 deletions
|
@ -11,8 +11,9 @@ class VarnishPurger extends Extension {
|
|||
private function curl_purge($path) {
|
||||
$url = make_http(make_link($path));
|
||||
$ch = curl_init();
|
||||
curl_setopt($ch, CURLOPT_URL,$url);
|
||||
curl_setopt($ch, CURLOPT_URL, $url);
|
||||
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "PURGE");
|
||||
curl_setopt($ch, CURLOPT_TIMEOUT, 5);
|
||||
$result = curl_exec($ch);
|
||||
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
|
||||
curl_close($ch);
|
||||
|
|
Reference in a new issue