I am trying to pass in a CommaDelimitedList to populate a List of Certs in a AWS::ElasticLoadBalancingV2::ListenerCertificate resource.
Error: Value of property Certificates must be a list of objects
I tried a few formats, including the following:
Parameters:
pAdditionalAlbListenerCertArns:
Type: CommaDelimitedList
Default: "arn:someCert1, arnsomeCert2"
Description: enter list of the ACM Certificates (Arns)
## Resource Format 1 - I would think this way would work as the result is [thing1, thing2]
Resources:
rCertificatesList:
Type: AWS::ElasticLoadBalancingV2::ListenerCertificate
Properties:
Certificates: ! Ref pAdditionalAlbListenerCertArns
## Resource Format 2 - I know this should not work, because it's a single item trying to be populated by a list.
Resources:
rCertificatesList:
Type: AWS::ElasticLoadBalancingV2::ListenerCertificate
Properties:
Certificates:
CertificateArn: ! Ref pAdditionalAlbListenerCertArns
Apparently Cfn is not smart enough to prepend each item with CertificateArn:.
I have also tried combinations of !Split, !Sub, and !Join which gave the same error. Currently I am having to key in the certs directly, which is not viable. While I could create individual parameters for each cert, or use a !Select to grab them out of the list, I don't know how many I will have in each environment (DEV/TEST/PROD).
I know this works cleanly for things like security groups; am I missing something?
Thanks in advance!