feat: add support for generated elasticsearch mappings

Fixes #38
This commit is contained in:
Wieland Schöbl
2019-05-29 13:42:41 +02:00
committed by Rainer Killinger
parent 7e04fad28b
commit 8eab6b8531
30 changed files with 303 additions and 867 deletions

View File

@@ -16,6 +16,8 @@
import {SCConfigFile, SCPluginMetaData} from '@openstapps/core';
import {Validator} from '@openstapps/core-tools/lib/validate';
import * as config from 'config';
import {readFileSync} from 'fs';
import {resolve} from 'path';
import {BackendTransport} from './notification/backend-transport';
/**
@@ -42,3 +44,9 @@ export const isTestEnvironment = process.env.NODE_ENV !== 'production';
* Stores a ("key-value") list of plugins where key is route and value is plugin information
*/
export const plugins = new Map<string, SCPluginMetaData>();
/**
* The version of the installed core
*/
export const coreVersion: string = JSON.parse((readFileSync(resolve('.', '.', 'package.json'), 'utf-8')).toString())
.dependencies['@openstapps/core'];