serverless-pseudo-parameters icon indicating copy to clipboard operation
serverless-pseudo-parameters copied to clipboard

Documentation regarding use of AWS pseudo parameters natively could be more helpful

Open phaakma opened this issue 3 years ago • 0 comments

Hi.

Thanks for the comment re this plugin being deprecated, but I struggled to implement without it based on the documentation available in this repo and from the Serverless Framework documentation.

It wasn't until I stumbled on this link from one of the Serverless Forum pages that I realised that not only do you need to replace the '#' with '$', you seem to need to add '!Sub' at the beginning.

ie. Resource: 'arn:aws:lambda:#{AWS::Region}:#{AWS::AccountId}:function:function-on-error' becomes: Resource: !Sub 'arn:aws:lambda:${AWS::Region}:${AWS::AccountId}:function:function-on-error'

https://forum.serverless.com/t/pseudo-parameters-with-variables/13119

I think it would be very helpful for others if this little tip could be added to the documentation page here.

phaakma avatar Jan 10 '22 05:01 phaakma