mirror of
https://gitlab.com/openstapps/openstapps.git
synced 2026-01-22 01:22:54 +00:00
feat: add backend
This commit is contained in:
30
config/elasticsearch-b-tu.ts
Normal file
30
config/elasticsearch-b-tu.ts
Normal file
@@ -0,0 +1,30 @@
|
||||
import { ElasticsearchConfigFile } from '../src/storage/elasticsearch/Elasticsearch';
|
||||
|
||||
/**
|
||||
* A partial type which is recursive
|
||||
*
|
||||
* Copied and only modified array type from `[]` to `Array<>` from https://stackoverflow.com/a/51365037
|
||||
*/
|
||||
type RecursivePartial<T> = {
|
||||
[P in keyof T]?:
|
||||
T[P] extends Array<(infer U)> ? Array<RecursivePartial<U>> :
|
||||
T[P] extends object ? RecursivePartial<T[P]> :
|
||||
T[P];
|
||||
};
|
||||
|
||||
/**
|
||||
* This is the database configuration for the technical university of berlin
|
||||
*/
|
||||
const config: RecursivePartial<ElasticsearchConfigFile> = {
|
||||
internal: {
|
||||
database: {
|
||||
name: 'elasticsearch',
|
||||
query: {
|
||||
minMatch: '60%',
|
||||
queryType: 'query_string',
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
export default config;
|
||||
Reference in New Issue
Block a user