Skip to content

Commit 4372426

Browse files
committed
Install scout
1 parent d3f2e4d commit 4372426

File tree

4 files changed

+230
-1
lines changed

4 files changed

+230
-1
lines changed

composer.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,14 @@
55
"type": "project",
66
"require": {
77
"php": "^7.3",
8+
"algolia/algoliasearch-client-php": "^2.2",
89
"doctrine/dbal": "^2.5",
910
"facade/ignition": "^1.0",
1011
"fideloper/proxy": "^4.0",
1112
"guzzlehttp/guzzle": "^6.3",
1213
"laravel/framework": "^6.0",
1314
"laravel/horizon": "^3.2.7",
15+
"laravel/scout": "^8.0",
1416
"laravel/socialite": "^4.2",
1517
"laravel/tinker": "^1.0",
1618
"lasserafn/php-initial-avatar-generator": "^2.0",

composer.lock

Lines changed: 136 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

config/scout.php

Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,91 @@
1+
<?php
2+
3+
return [
4+
5+
/*
6+
|--------------------------------------------------------------------------
7+
| Default Search Engine
8+
|--------------------------------------------------------------------------
9+
|
10+
| This option controls the default search connection that gets used while
11+
| using Laravel Scout. This connection is used when syncing all models
12+
| to the search service. You should adjust this based on your needs.
13+
|
14+
| Supported: "algolia", "null"
15+
|
16+
*/
17+
18+
'driver' => env('SCOUT_DRIVER', 'algolia'),
19+
20+
/*
21+
|--------------------------------------------------------------------------
22+
| Index Prefix
23+
|--------------------------------------------------------------------------
24+
|
25+
| Here you may specify a prefix that will be applied to all search index
26+
| names used by Scout. This prefix may be useful if you have multiple
27+
| "tenants" or applications sharing the same search infrastructure.
28+
|
29+
*/
30+
31+
'prefix' => env('SCOUT_PREFIX', ''),
32+
33+
/*
34+
|--------------------------------------------------------------------------
35+
| Queue Data Syncing
36+
|--------------------------------------------------------------------------
37+
|
38+
| This option allows you to control if the operations that sync your data
39+
| with your search engines are queued. When this is set to "true" then
40+
| all automatic data syncing will get queued for better performance.
41+
|
42+
*/
43+
44+
'queue' => env('SCOUT_QUEUE', false),
45+
46+
/*
47+
|--------------------------------------------------------------------------
48+
| Chunk Sizes
49+
|--------------------------------------------------------------------------
50+
|
51+
| These options allow you to control the maximum chunk size when you are
52+
| mass importing data into the search engine. This allows you to fine
53+
| tune each of these chunk sizes based on the power of the servers.
54+
|
55+
*/
56+
57+
'chunk' => [
58+
'searchable' => 500,
59+
'unsearchable' => 500,
60+
],
61+
62+
/*
63+
|--------------------------------------------------------------------------
64+
| Soft Deletes
65+
|--------------------------------------------------------------------------
66+
|
67+
| This option allows to control whether to keep soft deleted records in
68+
| the search indexes. Maintaining soft deleted records can be useful
69+
| if your application still needs to search for the records later.
70+
|
71+
*/
72+
73+
'soft_delete' => false,
74+
75+
/*
76+
|--------------------------------------------------------------------------
77+
| Algolia Configuration
78+
|--------------------------------------------------------------------------
79+
|
80+
| Here you may configure your Algolia settings. Algolia is a cloud hosted
81+
| search engine which works great with Scout out of the box. Just plug
82+
| in your application ID and admin API key to get started searching.
83+
|
84+
*/
85+
86+
'algolia' => [
87+
'id' => env('ALGOLIA_APP_ID', ''),
88+
'secret' => env('ALGOLIA_SECRET', ''),
89+
],
90+
91+
];

phpunit.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,5 +36,6 @@
3636
<env name="MAIL_DRIVER" value="array"/>
3737
<env name="SESSION_DRIVER" value="array"/>
3838
<env name="QUEUE_CONNECTION" value="sync"/>
39+
<env name="SCOUT_DRIVER" value="null"/>
3940
</php>
4041
</phpunit>

0 commit comments

Comments
 (0)