There’s an outstanding PR for this functionality in-progress right now.
You could definitely do this in CloudFormation (under the resources
section of your serverless.yml
) too, if you can’t wait. You’d need to use Serverless Variables to generate your function names on the fly in order to make it work.