- Neueste
- Die meisten Stimmen
- Die meisten Kommentare
Hi there,
Hope you are doing well!
If the key concern is to make sure the Stack Instance[1] of your stackset, basically the individual stack managed by the stackset, can create resources with value based on which account the stack isntance was CURRENTLY deployed into, there is a straight forward feature Pseudo parameters reference AWS::AccountId you can leverage.
For instance, in the template, you can simply assign current account ID value with !Ref intrinsic function[3]:
JSON: "ExternalID" : { "Ref" : "AWS::AccountId" }
YAML: ExternalID: Ref: AWS::AccountId
In this approach, no SSM parameters and Dynamic References need to be involved.
Regards.
References: [1] https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/stacksets-concepts.html#stacksets-concepts-stackinstances [2] https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/pseudo-parameter-reference.html#cfn-pseudo-param-accountid
Relevanter Inhalt
- AWS OFFICIALAktualisiert vor einem Jahr
- AWS OFFICIALAktualisiert vor 3 Jahren
- AWS OFFICIALAktualisiert vor 10 Monaten
- AWS OFFICIALAktualisiert vor 2 Jahren