aws-bootstrap icon indicating copy to clipboard operation
aws-bootstrap copied to clipboard

PDF-book Version 1.3, 2020-02-03: error when setting up nested Staging stack

Open erovira opened this issue 5 years ago • 1 comments
trafficstars

Hey @dvassallo , fist of all thank you for such an awesome book. I feel like it's a great way to get my feet wet on infrastructure-as-code on AWS :muscle:

I had an issue when setting up the nested Staging stack. By following the book's instructions in the section Creating a nested stack for staging I got the following error when attempting to deploy the infra:

Unable to fetch parameters ami-XXXXXX from parameter store for this account cloudformation

under the logical id Staging.

I came here to compare my code and found the issue: When the book says to create stage.yml as a copy of main.yml, after following the steps, we end up with the following EC2AMI in stage.yml:

EC2AMI:
    Type: 'AWS::SSM::Parameter::Value<AWS::EC2::Image::Id>'
    Default: '/aws/service/ami-amazon-linux-latest/amzn2-ami-hvm-x86_64-gp2'

which causes the error. By changing it to a Type: String like here https://github.com/good-parts/aws-bootstrap/commit/629ab65d00234dd4927c169a9122978d6cdb7d5c#diff-66ce0f88586a9e9a7f4f95e1483718f6R7 it got sorted out.

I searched in the book (V1.3) and didn't find any mention of this. Apologies in case I missed it!

Thanks.

erovira avatar May 03 '20 23:05 erovira

I had the same issue and required the same fix.

phiniezyc avatar Feb 15 '21 01:02 phiniezyc