Transform relative stack paths in a CloudFormation template into full S3 URLs
$ npm install --save cfn-nest
Given a pseudo-valid nested stack template:
cfn-nest template.json --bucket my-templates
Any nested templates will be uploaded to S3 as required by CloudFormation. The
Template property will be replaced by a valid
TemplateURL. This URL contains an MD5 hash of the file contents so different versions will always produce unique URLs. Un-nesting is performed recursively so you can write templates that reference templates that reference other templates (and so on).
Template path is resolved relative to the template source file.
var CfnNest =var JSONStream =var through =fs
Creates a new
Transform stream that expects parsed CloudFormation template objects as input.
The name of the S3 bucket to use.
The working directory to use when resolving template paths.
A listener that will be called after each file upload. The
file is an object with
s3 path properties.
MIT © Ben Drucker