Reputation: 8096
I would like to create a custom resource in cloudformation that will contain sub resources so that I can prevision application resources for high value clients.
For example. I have an application that has an SNS::Subscription
, SQS::Queue
, ElasticBeanstalk::Environment
, ElasticBeanstalk::Application
and ElasticBeanstalk::ApplicationVersion
.
Copying this for any client I want to provision dedicated resources for is a hassle. Keeping them all up to date is a problem.
I would like to define these once, and use a custom resource to generate them with custom variables provided. Like-
GeneralPurpose:
Type: COM::MyApplication
Properties:
QueueName: general
InstanceType: t3.micro
Instances: 30
AcmeClient:
Type: COM::MyApplication
Properties:
QueueName: acme
InstanceType: t5.medium
Instances: 10
SnsFilterValue: acme
These custom properties would be used in the custom resource template I defined and generate all the resources required for both the general
and acme
application.
If I need to change the default visibility timeout for the application queue, I can do it in one place and update all resources that used this custom resource.
Is this possible?
Upvotes: 0
Views: 167
Reputation: 4596
Consider using a nested stacks instead of a custom resource. You can define parameterized templates to use as the nested stacks. This will be much easier to maintain.
Upvotes: 1