Skip to content

Commit

Permalink
Get the core file location from config
Browse files Browse the repository at this point in the history
When using Solr and Docker, it's common for files to actually live in a different location than where the instance path is.

To overcome this, it's now possible to set the `solr_path`, as the path where the files should live according to Solr.
  • Loading branch information
Firesphere authored May 8, 2023
1 parent 6633ac1 commit 93325a6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Traits/CoreTraits/CoreAdminTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@ public function coreCreate($core, $configStore): bool
$action = $this->admin->createCreate();

$action->setCore($core);
$action->setInstanceDir($configStore->instanceDir($core));
$path = SolrCoreService::config()->get('solr_path') ?? $configStore->instanceDir($core);
$action->setInstanceDir($path);
$this->admin->setAction($action);
try {
$response = $this->client->coreAdmin($this->admin);
Expand Down

0 comments on commit 93325a6

Please sign in to comment.