Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save suz-lab/0a345a7d1f3fd30858a9 to your computer and use it in GitHub Desktop.
Save suz-lab/0a345a7d1f3fd30858a9 to your computer and use it in GitHub Desktop.
{
"AWSTemplateFormatVersion": "2010-09-09",
"Parameters": {
"ProjectName": {
"Type": "String",
"Default": "suzlab"
},
"DbSubnetGroupName": {
"Type": "String",
"Default": "xxxxxxxx"
},
"VpcSecurityGroup": {
"Type": "AWS::EC2::SecurityGroup::Id",
"Default": "sg-yyyyyyyy"
}
},
"Resources": {
"DbInstance": {
"Type": "AWS::RDS::DBInstance",
"Properties": {
"AllocatedStorage": "5",
"DBInstanceClass": "db.t2.micro",
"DBSnapshotIdentifier": "xxxxxxxx-snapshot-dbinstance",
"DBSubnetGroupName": { "Ref": "DbSubnetGroupName" },
"DBInstanceIdentifier": { "Ref": "ProjectName" },
"VPCSecurityGroups": [ { "Ref": "VpcSecurityGroup"} ],
"MasterUserPassword": { "Fn::Join" : [ "", [
{ "Ref": "ProjectName" },
"!Z3"
] ] }
},
"DeletionPolicy": "Snapshot"
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment