From e294fe85f1e604739466dfa966fa54b1dccbd8a4 Mon Sep 17 00:00:00 2001 From: KevFan Date: Tue, 2 Jun 2020 16:06:27 +0100 Subject: [PATCH] export fuse namespace attribute dependant on install type --- src/common/docsHelpers.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/common/docsHelpers.js b/src/common/docsHelpers.js index 991a54452..640ee85fe 100644 --- a/src/common/docsHelpers.js +++ b/src/common/docsHelpers.js @@ -96,7 +96,8 @@ const getMiddlewareServiceAttrs = middlewareServices => { 'amq-broker-amqp-url': middlewareServices.amqCredentials.url, 'amq-credentials-username': middlewareServices.amqCredentials.username, 'amq-credentials-password': middlewareServices.amqCredentials.password, - 'apicurio-url': getUrlFromMiddlewareServices(middlewareServices, DEFAULT_SERVICES.APICURIO) + 'apicurio-url': getUrlFromMiddlewareServices(middlewareServices, DEFAULT_SERVICES.APICURIO), + 'fuse-namespace': getFuseNamespace(username) }; if (window.OPENSHIFT_CONFIG && window.OPENSHIFT_CONFIG.optionalProvisionServices.length > 0) { @@ -143,4 +144,12 @@ const getDefaultAdocAttrs = walkthroughId => ({ imagesdir: `/walkthroughs/${walkthroughId}/files/` }); +const getFuseNamespace = userName => { + if (isWorkshopInstallation) { + return `${userName}-fuse`; + } + + return 'redhat-rhmi-fuse'; +}; + export { getDocsForWalkthrough, getDefaultAdocAttrs, getWorkshopUrl, getOpenshiftHost, isWorkshopInstallation };