Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for multiple serverless.yml #37

Open
kkesley opened this issue May 1, 2019 · 2 comments
Open

Support for multiple serverless.yml #37

kkesley opened this issue May 1, 2019 · 2 comments

Comments

@kkesley
Copy link

kkesley commented May 1, 2019

Hi is there any way to combine documentation from multiple serverless.yml? So I'm thinking about using a file for documentation and multiple serverless.yml can refer to it. And when generating, it'd generate 1 document

@zyrorl
Copy link
Collaborator

zyrorl commented May 30, 2019

Yes you can, just refer to the same documentation files in different projects using the ${file(../myFile.yml)} property

@antonydellavecchia
Copy link

I get the following error when trying to reference an external yaml file,
any suggestions? openapi generate works when i write the config locally

`custom:
${file(../../serverless.common.yml):custom}

Error: [ERROR clone] Invalid parameters
at Object.Clone.clone (/home/antony/live-eo-product-api/node_modules/src/clone/clone.ts:38:26)
at new DefinitionGenerator (/home/antony/live-eo-product-api/node_modules/src/DefinitionGenerator.ts:25:19)
at ServerlessOpenApiDocumentation.generate (/home/antony/live-eo-product-api/node_modules/src/ServerlessOpenApiDocumentation.ts:107:23)
at /usr/lib/node_modules/serverless/lib/classes/PluginManager.js:490:55
at tryCatcher (/usr/lib/node_modules/serverless/node_modules/bluebird/js/release/util.js:16:23)
at Object.gotValue (/usr/lib/node_modules/serverless/node_modules/bluebird/js/release/reduce.js:168:18)
at Object.gotAccum (/usr/lib/node_modules/serverless/node_modules/bluebird/js/release/reduce.js:155:25)
at Object.tryCatcher (/usr/lib/node_modules/serverless/node_modules/bluebird/js/release/util.js:16:23)
at Promise._settlePromiseFromHandler (/usr/lib/node_modules/serverless/node_modules/bluebird/js/release/promise.js:547:31)
at Promise._settlePromise (/usr/lib/node_modules/serverless/node_modules/bluebird/js/release/promise.js:604:18)
at Promise._settlePromiseCtx (/usr/lib/node_modules/serverless/node_modules/bluebird/js/release/promise.js:641:10)
at _drainQueueStep (/usr/lib/node_modules/serverless/node_modules/bluebird/js/release/async.js:97:12)
at _drainQueue (/usr/lib/node_modules/serverless/node_modules/bluebird/js/release/async.js:86:9)
at Async._drainQueues (/usr/lib/node_modules/serverless/node_modules/bluebird/js/release/async.js:102:5)
at Immediate.Async.drainQueues [as _onImmediate] (/usr/lib/node_modules/serverless/node_modules/bluebird/js/release/async.js:15:14)
at processImmediate (internal/timers.js:456:21)
at process.topLevelDomainCallback (domain.js:137:15)
`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants