Search code examples
amazon-web-servicesamazon-s3stackaws-cloudformationgoogle-cloud-endpoints

How to build CloudFormation template from multiple yml


I'm trying to get this repo going here - https://github.com/mydatastack/google-analytics-to-s3.

A link is provided to launch the AWS CloudFormation stack but it is no longer working as the S3 bucket containing the template is no longer active.

I have 2 questions about getting data pipeline running:

  1. My first question would be what is 631216aef6ab2824fc63572d1d3d5e6c.template and can I create it through the 3 .yml files in the CloudFormation folder?

I've tried to create a template through CloudFormation designer collector-ga.yml template, collector-ga.yml but it fails. I think its because the Resources within the yml aren't available when creating a template just from collector-ga. I've also tried uploading the repo to s3 and creating a template from there but that was also unsuccessful.

  1. How can I launch the stack from the repo? I've found very little information online so an explanation or a pointer to some relevant resources would be appreciated.

Solution

  • This repository doesn't use the "standard" CloudFormation resources, but it uses AWS SAM. You'll have to install the SAM CLI tool and use that to deploy the CloudFormation stack. If you run sam deploy --guided it will help you with the setup of the necessary S3 bucket etc on your AWS account. SAM will upload the necessary files, resolve the internal local links between the templates by updating them with the S3 URLs and construct a packaged.yml template which it will use to deploy the stack.

    Also, check out the AWS SAM user guide for more information.