File tree Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -62,6 +62,7 @@ The following parameters can be set in config files or in env variables:
62
62
- ES.ES_INDEX: Elasticsearch index name
63
63
- ES.ES_REFRESH: Elasticsearch refresh method. Default to string ` true ` (i.e. refresh immediately)
64
64
- FILE_UPLOAD_SIZE_LIMIT: the file upload size limit in bytes
65
+ - OPENSEARCH: Flag to use Opensearch NPM instead of Elasticsearch
65
66
- RESOURCES_API_URL: TC resources API base URL
66
67
- GROUPS_API_URL: TC groups API base URL
67
68
- PROJECTS_API_URL: TC projects API base URL
Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ module.exports = {
40
40
41
41
ES : {
42
42
// above AWS_REGION is used if we use AWS ES
43
- HOST : process . env . ES_HOST || "localhost:9200" ,
43
+ HOST : process . env . OS_HOST || "localhost:9200" ,
44
44
API_VERSION : process . env . ES_API_VERSION || "6.8" ,
45
45
OPENSEARCH : process . env . OPENSEARCH || "false" ,
46
46
ES_INDEX : process . env . ES_INDEX || "challenge" ,
Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ const HttpStatus = require("http-status-codes");
17
17
const xss = require ( "xss" ) ;
18
18
const logger = require ( "./logger" ) ;
19
19
20
- const { Client : ESClient } = require ( "@opensearch-project/opensearch" ) ;
20
+ const { Client : OSClient } = require ( "@opensearch-project/opensearch" ) ;
21
21
const elasticsearch = require ( "elasticsearch" ) ;
22
22
23
23
const projectHelper = require ( "./project-helper" ) ;
@@ -734,7 +734,7 @@ function getESClient() {
734
734
} ) ;
735
735
}
736
736
} else {
737
- esClient = new ESClient ( {
737
+ esClient = new OSClient ( {
738
738
node : esHost ,
739
739
ssl : {
740
740
rejectUnauthorized : false ,
You can’t perform that action at this time.
0 commit comments