I'm using yaml. So, we can use either:
!GetAtt [ WebServer, AvailabilityZone ]
!GetAtt WebServer.AvailabilityZone
Also, we can use:
!Sub 'sometext-${AWS::StackName}'
how can I use GetAtt output instead of ${AWS::StackName}
, preferably using the second form of GetAtt
? I do know how to use Join
but I'd like to stay with Sub
.
Simply remove !GetAtt and reference the desired variable. In the following code EIP.AllocationId normally returned via !GetAtt.