From c8c291fded3a7168ed5072f3897b4724ebabfb4e Mon Sep 17 00:00:00 2001 From: undefined Date: Fri, 18 Mar 2022 22:51:35 +0800 Subject: [PATCH] elastic: fix endpoint setting --- packages/elastic/script.ts | 2 +- packages/elastic/setting.yaml | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 packages/elastic/setting.yaml diff --git a/packages/elastic/script.ts b/packages/elastic/script.ts index 3a07edb42..0e269e476 100644 --- a/packages/elastic/script.ts +++ b/packages/elastic/script.ts @@ -6,7 +6,7 @@ import * as system from 'hydrooj/src/model/system'; import { iterateAllProblem, iterateAllProblemInDomain } from 'hydrooj/src/pipelineUtils'; import * as bus from 'hydrooj/src/service/bus'; -const client = new Client({ node: system.get('elasticsearch.url') || 'http://192.168.1.82:9200' }); +const client = new Client({ node: system.get('elastic-search.url') || 'http://127.0.0.1:9200' }); const indexOmit = ['_id', 'docType', 'data', 'additional_file', 'config', 'stats', 'assign']; diff --git a/packages/elastic/setting.yaml b/packages/elastic/setting.yaml new file mode 100644 index 000000000..aea785885 --- /dev/null +++ b/packages/elastic/setting.yaml @@ -0,0 +1,2 @@ +url: + value: http://127.0.0.1:9200