fix(backend): Use SSL option for Meilisearch (#10772)

This commit is contained in:
Caipira 2023-05-06 04:02:34 +09:00 committed by GitHub
parent 4a72941eda
commit ae21b75687
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 6 additions and 1 deletions

View file

@ -102,6 +102,7 @@ redis:
# host: meilisearch
# port: 7700
# apiKey: ''
# ssl: true
# ┌───────────────┐
#───┘ ID generation └───────────────────────────────────────────

View file

@ -102,6 +102,7 @@ redis:
# host: localhost
# port: 7700
# apiKey: ''
# ssl: true
# ┌───────────────┐
#───┘ ID generation └───────────────────────────────────────────

View file

@ -102,6 +102,7 @@ redis:
# host: meilisearch
# port: 7700
# apiKey: ''
# ssl: true
# ┌───────────────┐
#───┘ ID generation └───────────────────────────────────────────

View file

@ -123,6 +123,7 @@ redis:
# host: localhost
# port: 7700
# apiKey: ''
# ssl: true
# ┌───────────────┐
#───┘ ID generation └───────────────────────────────────────────

View file

@ -28,7 +28,7 @@ const $meilisearch: Provider = {
useFactory: (config) => {
if (config.meilisearch) {
return new MeiliSearch({
host: `http://${config.meilisearch.host}:${config.meilisearch.port}`,
host: `${config.meilisearch.ssl ? 'https' : 'http' }://${config.meilisearch.host}:${config.meilisearch.port}`,
apiKey: config.meilisearch.apiKey,
});
} else {

View file

@ -61,6 +61,7 @@ export type Source = {
host: string;
port: string;
apiKey: string;
ssl?: boolean;
};
proxy?: string;