nl_tokens: Builds templates nested in the main template using the specified config and cf file paths
pl_tokens: function buildNestedCfs ( config , KesClass , options ) { const limit = pLimit ( 1 ) ; if ( config . nested_templates ) { const nested = config . nested_templates ; console . log ( 'Nested templates are found!' ) ; const ps = Object . keys ( nested ) . map ( ( name ) => limit ( ( ) => { console . log ( ` ${ name } ` ) ; const newOptions = Object . assign ( { } , options ) ; newOptions . cfFile = nested [ name ] . cfFile ; newOptions . configFile = nested [ name ] . configFile ; // no templates are used in nested stacks delete newOptions . template ; delete newOptions . deployment ; // use the parent stackname newOptions . stack = config . stack ; newOptions . parent = config ; const nestedConfig = new Config ( newOptions ) ; // get the bucket name from the parent if ( ! nestedConfig . bucket ) { nestedConfig . bucket = utils . getSystemBucket ( config ) ; } // add nested deployment name nestedConfig . nested_cf_name = name ; const kes = new KesClass ( nestedConfig ) ; return kes . uploadCF ( ) . then ( ( uri ) => { config . nested_templates [ name ] . url = uri ; } ) ; } ) ) ; return Promise . all ( ps ) . <mask> ( ( ) => config ) . catch ( utils . failure ) ; } return Promise . resolve ( config ) ; }