diff --git a/.env.example b/.env.example index 6becda6c..f6b634d7 100644 --- a/.env.example +++ b/.env.example @@ -65,3 +65,9 @@ GEOIP2_DATABASE= EXAM_PROGRESS_UPDATE_PROBABILITY=20 TRACKER_API_LOCAL_HOST= + +ELASTICSEARCH_HOST= +ELASTICSEARCH_PORT= +ELASTICSEARCH_SCHEME= +ELASTICSEARCH_USER= +ELASTICSEARCH_PASS= diff --git a/config/explorer.php b/config/explorer.php index 4eaa1edf..dd7b1a88 100644 --- a/config/explorer.php +++ b/config/explorer.php @@ -9,9 +9,12 @@ return [ * https://www.elastic.co/guide/en/elasticsearch/client/php-api/current/configuration.html */ 'connection' => [ - 'host' => 'localhost', - 'port' => '9200', - 'scheme' => 'http', + 'host' => env('ELASTICSEARCH_HOST','localhost'), + 'port' => env('ELASTICSEARCH_PORT','9200'), + 'scheme' => env('ELASTICSEARCH_SCHEME','https'), + 'user' => env('ELASTICSEARCH_USER','elastic'), + 'pass' => env('ELASTICSEARCH_PASS',''), + ], /**