1 Answer
- Newest
- Most votes
- Most comments
0
For SSM parameters shared by another AWS account, enter the full parameter ARN.
for example:
Resources:
MyEC2Instance:
Type: 'AWS::EC2::Instance'
Properties:
# Other EC2 properties...
UserData:
Fn::Base64:
Fn::Sub: |
#!/bin/bash
echo "${MyParameter}"
Parameters:
MyParameter:
Description: SSM parameter value
Type: 'AWS::SSM::Parameter::Value<String>'
Default: 'arn:aws:ssm:REGION:SOURCE_ACCOUNT_ID:parameter/PARAMETER_NAME'
I tried the suggested approach but I am getting an error
An error ocurred (Internal Failure) when calling the CreateChangeSet operation (reached max retries: 2) Unknown
I did upgrade the AWS CLI to version 2.15. Also I was able to run
aws ssm get-parameter --name <remote-parameter-arn>
from the target account without any issues..after running
cfn-lint -t mytemplate.yml
I got the following responseW2506 Parameter LatestAmiId should be of type [AWS::EC2::Image::Id, AWS::SSM::Parameter::Value<AWS::EC2::Image::Id>]
Tried the approach and got the same results.
can you provide a full CF Template ?
Relevant content
- asked 6 months ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 21 days ago
- AWS OFFICIALUpdated 2 months ago
please accept the answer if it was useful for you