I use CloudFormation's AWS::RDS::DBCluster
resource to create my Aurora MySQL database cluster.
My question is, has anyone created stored procedures as well as events in Aurora MySQL via CloudFormation? Is that even possible?
Delivering these via CloudFormation would allow me to recreate the infrastructure without deploying the stored procedures and events separately.
There's no way to configure stored procedures and events with the
AWS::RDS::DBCluster
CloudFormation resource directly.My suggestion would be to provision an
AWS::EC2::Instance
containing aUserData
script that installs the mysql client, then executes the contents of a user-provided MySQL script creating events/stored-procedures on the newly-created DB instance.