Skip to content

Commit

Permalink
Merge pull request #99 from bastienu/auth-for-v2
Browse files Browse the repository at this point in the history
Add Basic Auth.
  • Loading branch information
Jeroen-G authored Jun 15, 2022
2 parents 5ffd1a8 + 26c4fc1 commit 84b7fbb
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/ExplorerServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,13 @@ public function boot(): void
);
}

if(config()->has('explorer.connection.auth')) {
$client->setBasicAuthentication(
config('explorer.connection.auth.username'),
config('explorer.connection.auth.password')
);
}

return new ElasticClientFactory($client->build());
});

Expand Down

0 comments on commit 84b7fbb

Please sign in to comment.