I am creating an RDS instance using CloudFormation using this:
"Resources": { "myDB": { "Type": "AWS::RDS::DBInstance", "Properties": { "AllocatedStorage": "5", "DBInstanceClass": "db.m1.small", "Engine": "MySQL", "EngineVersion": "5.5", "DBName": "mydb", "MasterUsername": { "Ref": "DBUser" }, "MasterUserPassword": { "Ref": "DBPassword" }, "DBParameterGroupName": { "Ref": "myRDSParamGroup" } } }
and it all works. But I need to run initial SQL on the DB when its created, to setup my apps schema. My current approach is to have the app self migrating, but I'd like to do it in the CloudFormation definition. Is this possible?