diff --git a/api/src/engine/engine.constants.ts b/api/src/engine/engine.constants.ts index 3c9ae327491d37456964f9ce2cba8a7f04ecccf5..641ceed91bb4a29953fc558479f5b667fd112808 100644 --- a/api/src/engine/engine.constants.ts +++ b/api/src/engine/engine.constants.ts @@ -1,3 +1,4 @@ export const ENGINE_MODULE_OPTIONS = 'EngineModuleOption'; export const ENGINE_SERVICE = 'EngineService'; export const ENGINE_SKIP_TOS = 'TOS_SKIP'; +export const ENGINE_ONTOLOGY_URL = 'ONTOLOGY_URL'; diff --git a/api/src/engine/engine.resolver.ts b/api/src/engine/engine.resolver.ts index 6260111702f3268881409f80f5db91cc197c1cba..d5acde6a200cda20f7105e610713c3cf407fac79 100644 --- a/api/src/engine/engine.resolver.ts +++ b/api/src/engine/engine.resolver.ts @@ -6,6 +6,7 @@ import { GQLRequest } from '../common/decorators/gql-request.decoractor'; import { Md5 } from 'ts-md5'; import { ENGINE_MODULE_OPTIONS, + ENGINE_ONTOLOGY_URL, ENGINE_SERVICE, ENGINE_SKIP_TOS, } from './engine.constants'; @@ -55,6 +56,7 @@ export class EngineResolver { true, ), matomo, + ontologyUrl: this.configSerivce.get(ENGINE_ONTOLOGY_URL), }; const version = Md5.hashStr(JSON.stringify(data)); diff --git a/api/src/engine/models/configuration.model.ts b/api/src/engine/models/configuration.model.ts index 6ffe779cc55962c0dc0c20fd0e3d47c9e4d73348..9471881a191b9bdbc33a8d181487f6888d453fc3 100644 --- a/api/src/engine/models/configuration.model.ts +++ b/api/src/engine/models/configuration.model.ts @@ -25,4 +25,7 @@ export class Configuration { @Field(() => Matomo, { nullable: true }) matomo?: Matomo; + + @Field({ nullable: true }) + ontologyUrl?: string; } diff --git a/api/src/schema.gql b/api/src/schema.gql index b93416b7bc8ea2912afd24c7382492d42b6c3809..8265eb01a39457cb2d9420de4625a1b937ac26d7 100644 --- a/api/src/schema.gql +++ b/api/src/schema.gql @@ -40,6 +40,7 @@ type Configuration { skipTos: Boolean enableSSO: Boolean matomo: Matomo + ontologyUrl: String } type Dataset { diff --git a/docs/for-developers/configuration/gateway.md b/docs/for-developers/configuration/gateway.md index 2b16dacfcbdfbc415f9091c3086a000032787d21..7f879ca3369f383b0f2b26fbacc31d35d889258b 100644 --- a/docs/for-developers/configuration/gateway.md +++ b/docs/for-developers/configuration/gateway.md @@ -18,6 +18,7 @@ description: >- | GATEWAY\_PORT | number | 8081 | Indicate the port that should be used by the gateway | | NODE\_ENV | string | dev | Value can be `prod` or `dev` | | BASE\_URL\_CONTEXT | string | null | Define context of the gateway. E.g. `api` if the api is under `http://127.0.0.1/api/` | +| ONTOLOGY\_URL | string | null | Define ontology's url | #### Authentication