a127-magic
Advanced tools
Comparing version 0.2.0 to 0.2.1
@@ -24,3 +24,3 @@ 'use strict'; | ||
'a127.magic': { | ||
swaggerFile: path.resolve(APP_ROOT, 'api/swagger/swagger.yaml'), | ||
swaggerFile: 'api/swagger/swagger.yaml', | ||
controllers: { | ||
@@ -56,5 +56,17 @@ useStubs: false, | ||
config = _.extend(BASE_DEFAULTS, defaultConfig, currentConfig, secrets); | ||
resolveRelativeProjectPaths(config); | ||
return config; | ||
} | ||
function resolveRelativeProjectPaths(config) { | ||
var magic = config['a127.magic']; | ||
magic.swaggerFile = path.resolve(APP_ROOT, magic.swaggerFile); | ||
if (_.isString(magic.controllers.controllers)) { | ||
magic.controllers.controllers = path.resolve(APP_ROOT, magic.controllers.controllers); | ||
} | ||
magic.volos.helpers = path.resolve(APP_ROOT, magic.volos.helpers); | ||
} | ||
// todo: actually use vault instead of file | ||
@@ -61,0 +73,0 @@ function readSecretsFromVault() { |
{ | ||
"name": "a127-magic", | ||
"version": "0.2.0", | ||
"version": "0.2.1", | ||
"description": "Apigee 127 Swagger Loader and Middleware", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
393
78232