Create a new CloudFormation template. We're going to add a total of 12 parameters to it:
- The first three parameters will contain the values we mentioned in the Getting ready section:
Parameters: VPCId: Type: AWS::EC2::VPC::Id Description: VPC where DB will launch SubnetIds: Type: List<AWS::EC2::Subnet::Id> Description: Subnets where the DB will launch (pick at least 2) SecurityGroupAllowCidr: Type: String Description: Allow this CIDR block to access the DB Default: "172.30.0.0/16"
- We're also going to add the database credentials as parameters. This is better than storing credentials in our infrastructure source code, but you should also investigate AWS Secret Manager and Parameter Store for even more secure options. ...