mkdir ~/environment/cf-template
cd ~/environment/cf-template
sudo curl --location -o ./template.yaml https://raw.githubusercontent.com/aws-samples/aws-serverless-application-catalog-workshop/master/template.yaml
Spare a few minutes to go through the CloudFormation template and understand how resources are being created based on the given parameters.
Take a look at the template.yaml
file downloaded. These are the main parameters we are going to use:
Parameter | Description |
---|---|
ProjectName | Project name |
RepositoryName | CodeCommit Repository name |
RepositoryDescription | CodeCommit Repository description |
CodeS3Bucket | Bucket name and path where our bundled code resides e.g. |
In a nutshell, these are the resources and tasks the template will provision and execute once it’s launched in AWS Service Catalog:
master
branch in our repository.buildspec.yml
, testspec.yml
, style-checker.yml
).If your company requires, AWS CodePipeline allows you to add Manual Approval steps between the promotion of each environment although you can achieve higher levels of safe deployments when you adopt a Blue/Green or Canary deployments.
Upload your template to the same bucket you created in the previous step.
cd ~/environment/cf-template
aws s3 cp template.yaml s3://serverless-wksp-sample-<FIRSTNAME-LASTNAME>/service-catalog/template.yaml
Go to your S3 console and confirm your upload has been completed successfully.
Copy the URL of your template.yaml
file to a notepad. You’ll need it in the next step.