Muhammad Mu'az
Muhammad Mu'az

Reputation: 368

Elasticsearch-PHP needs curl or custom http handler

i'm deploy laravel 5.2 to ubuntu and installed elasticquent lib and elasticsearch 2.3.4 , when i try to figure the result of aggregation :

RuntimeException in ClientBuilder.php line 144:
Elasticsearch-PHP requires cURL, or a custom HTTP handler.

I already install curl using command sudo apt-get install php5-curl and its still display the same error

How to fix it?

Thank you

Upvotes: 13

Views: 14347

Answers (2)

Jaydeep Rajput
Jaydeep Rajput

Reputation: 3673

sudo apt-get install php-curl

Try this, it will install curl as per your version of php.

Upvotes: 26

Morilog
Morilog

Reputation: 3045

You must run sudo apt-get install curl php5-curl to install curl and its php extension, if you are using PHP7, you must install php7.0-curl instead of php5-curl

Upvotes: 5

Related Questions