aws cdk typescript cloudfront certiifcate

0

Hello,

I am trying to pass existing certificate name (arn**) in below code.

  certificate: acm.Certificate.fromCertificateArn(this, 'ExistingCertificate', acmCertificateArn)

Hardcoding in a constant accepting where as pass through property not accepting. I am trying to save diff cert to diff env and pass the values dynamically which fails with undefined.

Could you suggest with code fix?

질문됨 3달 전177회 조회
1개 답변
0

Hello there,

Warm Greetings !

Thank you for reaching out to us with your concern.

I understand that you would like to know how you can pass the existing certificate ARN dynamically without hardcoding it.

I would like to highlight that assistance with application CDK code and code logic involves code support, I would like to take a moment to mention that assistance with code development or debugging is out of scope for AWS Premium Support. [+] AWS Support Scope - https://aws.amazon.com/premiumsupport/#Scope_of_AWS_Support

That being said, you may refer to some third party articles [1] which describes about using Certificate.fromCertificateArn class in CDK. Moreover, you may perform a lookup in your account by calling ListCertificates API to check the list of certificates if it is already existing in your account. Further, you may also refer to GitHub issues page [2] to seek guidance on dynamically passing the certificate ARNs.

Further, since code support is out of AWS Premium Support, and due to limited expertise with AWS CDK, we can assist you on best effort basis.

Hoping that the above helps.

References

[1] https://docs.aws.amazon.com/cdk/api/v1/docs/aws-certificatemanager-readme.html [2] https://github.com/aws/aws-cdk/issues/10792

AWS
지원 엔지니어
답변함 3달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인