diff --git a/lib/runtimeSettings.js b/lib/runtimeSettings.js index 7ac253e..23741fe 100644 --- a/lib/runtimeSettings.js +++ b/lib/runtimeSettings.js @@ -2,6 +2,7 @@ function getSettingsFile (settings) { const projectSettings = { credentialSecret: '', httpAdminRoot: '', + dashboardUI: '', disableEditor: '', codeEditor: 'monaco', theme: 'forge-light', @@ -31,6 +32,9 @@ function getSettingsFile (settings) { if (settings.settings.httpAdminRoot !== undefined) { projectSettings.httpAdminRoot = `httpAdminRoot: '${settings.settings.httpAdminRoot}',` } + if (settings.settings.dashboardUI !== undefined) { + projectSettings.dashboardUI = `ui: { path: '${settings.settings.dashboardUI}' },` + } if (settings.settings.disableEditor !== undefined) { projectSettings.disableEditor = `disableEditor: ${settings.settings.disableEditor},` } @@ -109,6 +113,7 @@ module.exports = { }), ${projectSettings.credentialSecret} ${projectSettings.httpAdminRoot} + ${projectSettings.dashboardUI} ${projectSettings.disableEditor} httpServerOptions: { "trust proxy": true diff --git a/test/unit/lib/runtimeSettings_spec.js b/test/unit/lib/runtimeSettings_spec.js index 41575d6..f912cea 100644 --- a/test/unit/lib/runtimeSettings_spec.js +++ b/test/unit/lib/runtimeSettings_spec.js @@ -29,6 +29,7 @@ describe('Runtime Settings', function () { const settings = await loadSettings(result) settings.should.not.have.property('credentialSecret') settings.should.not.have.property('httpAdminRoot') + settings.should.not.have.property('ui') // dashboardUI settings.should.not.have.property('disableEditor') settings.should.not.have.property('nodesDir') settings.should.have.property('editorTheme') @@ -85,6 +86,7 @@ describe('Runtime Settings', function () { }, settings: { httpAdminRoot: '/red', + dashboardUI: '/dash', disableEditor: true, codeEditor: 'ace', theme: 'forge-dark', @@ -113,6 +115,7 @@ describe('Runtime Settings', function () { const settings = await loadSettings(result) settings.should.have.property('credentialSecret', 'foo') settings.should.have.property('httpAdminRoot', '/red') + settings.should.have.property('ui', { path: '/dash' }) settings.should.have.property('disableEditor', true) settings.should.have.property('httpStorage', {