Difference between revisions of "AWS::RDS::DBInstance"

From wikieduonline
Jump to navigation Jump to search
 
(23 intermediate revisions by the same user not shown)
Line 1: Line 1:
 +
<code>[[AWS::RDS]]::DBInstance</code>
 
* https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-database-instance.html
 
* https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-database-instance.html
* Template [[snippets]]: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/quickref-rds.html
+
* Template [[Cloudformation snippets|snippets]]: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/quickref-rds.html
  
* <code>[[aws rds create-db-instance]]</code>
+
* [[AWS CloudFormation templates]]: https://s3.us-west-2.amazonaws.com/cloudformation-templates-us-west-2/RDS_Snapshot_On_Delete.template
* <code>[[aws cloudformation]] </code>
 
  
 
== Snippets ==
 
== Snippets ==
Line 11: Line 11:
  
 
  MyDB:
 
  MyDB:
   Type: AWS::RDS::DBInstance
+
   Type: [[AWS::RDS]]::DBInstance
 +
  Properties:
 +
    [[AllocatedStorage]]: '5'
 +
    [[DBInstanceClass]]: [[db.t2.micro]]
 +
    Engine: [[postgres]]
 +
    MasterUsername: MyName
 +
    MasterUserPassword: MyPassword
 +
  [[DeletionPolicy]]: Delete
 +
 
 +
Complete example: [[RDS_template.cf]]
 +
 
 +
* Engines: MySQL, postgres, ... https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html
 +
 
 +
 
 +
 
 +
MyDB:
 +
  Type: [[AWS::RDS]]::DBInstance
 
   Properties:
 
   Properties:
 
     [[DBSecurityGroups]]:
 
     [[DBSecurityGroups]]:
     - Ref: MyDbSecurityByEC2SecurityGroup
+
     - [[Ref:]] MyDbSecurityByEC2SecurityGroup
 
     - Ref: MyDbSecurityByCIDRIPGroup
 
     - Ref: MyDbSecurityByCIDRIPGroup
 
     AllocatedStorage: '5'
 
     AllocatedStorage: '5'
Line 21: Line 37:
 
     MasterUsername: MyName
 
     MasterUsername: MyName
 
     MasterUserPassword: MyPassword
 
     MasterUserPassword: MyPassword
   [[DeletionPolicy]]: Snapshot
+
   [[DeletionPolicy]]: Delete
 +
 
 +
 
 +
 
 +
Delete | Snapshot | Retain
 +
 
 +
== Complete example ==
 +
<pre>
 +
Type: AWS::RDS::DBInstance
 +
Properties:
 +
  AllocatedStorage: String
 +
  AllowMajorVersionUpgrade: Boolean
 +
  AssociatedRoles:
 +
    - DBInstanceRole
 +
  AutoMinorVersionUpgrade: Boolean
 +
  AvailabilityZone: String
 +
  BackupRetentionPeriod: Integer
 +
  CACertificateIdentifier: String
 +
  CharacterSetName: String
 +
  CopyTagsToSnapshot: Boolean
 +
  DBClusterIdentifier: String
 +
  DBInstanceClass: String
 +
  DBInstanceIdentifier: String
 +
  DBName: String
 +
  DBParameterGroupName: String
 +
  DBSecurityGroups:
 +
    - String
 +
  DBSnapshotIdentifier: String
 +
  DBSubnetGroupName: String
 +
  DeleteAutomatedBackups: Boolean
 +
  DeletionProtection: Boolean
 +
  Domain: String
 +
  DomainIAMRoleName: String
 +
  EnableCloudwatchLogsExports:
 +
    - String
 +
  EnableIAMDatabaseAuthentication: Boolean
 +
  EnablePerformanceInsights: Boolean
 +
  Engine: String
 +
  EngineVersion: String
 +
  Iops: Integer
 +
  KmsKeyId: String
 +
  LicenseModel: String
 +
  MasterUsername: String
 +
  MasterUserPassword: String
 +
  MaxAllocatedStorage: Integer
 +
  MonitoringInterval: Integer
 +
  MonitoringRoleArn: String
 +
  MultiAZ: Boolean
 +
  OptionGroupName: String
 +
  PerformanceInsightsKMSKeyId: String
 +
  PerformanceInsightsRetentionPeriod: Integer
 +
  Port: String
 +
  PreferredBackupWindow: String
 +
  PreferredMaintenanceWindow: String
 +
  ProcessorFeatures:
 +
    - ProcessorFeature
 +
  PromotionTier: Integer
 +
  PubliclyAccessible: Boolean
 +
  SourceDBInstanceIdentifier: String
 +
  SourceRegion: String
 +
  StorageEncrypted: Boolean
 +
  StorageType: String
 +
  Tags:
 +
    - Tag
 +
  Timezone: String
 +
  UseDefaultProcessorFeatures: Boolean
 +
  VPCSecurityGroups:
 +
    - String
 +
</pre>
  
 
== Related terms ==
 
== Related terms ==
* <code>[[Fn::GetAtt]]</code>
+
* <code>[[aws cloudformation create-stack]] </code>
* [[AWS Free Tier]]
+
* [[AWS CloudFormation functions]]: <code>[[Fn::GetAtt]]</code>
 +
* <code>[[aws rds create-db-instance]]</code>
 +
* <code>[[SourceDBInstanceIdentifier]]</code> for [[replicas]]
  
 
== See also ==
 
== See also ==
 +
* {{AWS::RDS}}
 
* {{aws rds}}
 
* {{aws rds}}
* {{aws cloudformation}}
 
 
* {{RDS}}
 
* {{RDS}}
* {{CloudFormation}}
 
  
 
[[Category:AWS]]
 
[[Category:AWS]]
 +
[[Category:CloudFormation]]

Latest revision as of 21:02, 1 June 2022

AWS::RDS::DBInstance

Snippets[edit]

PostgreSQL AWS Free Tier: db.t2.micro and 20 GB of database storage and backup.

MyDB:
  Type: AWS::RDS::DBInstance
  Properties:
    AllocatedStorage: '5'
    DBInstanceClass: db.t2.micro
    Engine: postgres
    MasterUsername: MyName
    MasterUserPassword: MyPassword
  DeletionPolicy: Delete 

Complete example: RDS_template.cf


MyDB:
  Type: AWS::RDS::DBInstance
  Properties:
    DBSecurityGroups:
    - Ref: MyDbSecurityByEC2SecurityGroup
    - Ref: MyDbSecurityByCIDRIPGroup
    AllocatedStorage: '5'
    DBInstanceClass: db.t2.micro
    Engine: PostgreSQL
    MasterUsername: MyName
    MasterUserPassword: MyPassword
  DeletionPolicy: Delete 


Delete | Snapshot | Retain

Complete example[edit]

Type: AWS::RDS::DBInstance
Properties: 
  AllocatedStorage: String
  AllowMajorVersionUpgrade: Boolean
  AssociatedRoles: 
    - DBInstanceRole
  AutoMinorVersionUpgrade: Boolean
  AvailabilityZone: String
  BackupRetentionPeriod: Integer
  CACertificateIdentifier: String
  CharacterSetName: String
  CopyTagsToSnapshot: Boolean
  DBClusterIdentifier: String
  DBInstanceClass: String
  DBInstanceIdentifier: String
  DBName: String
  DBParameterGroupName: String
  DBSecurityGroups: 
    - String
  DBSnapshotIdentifier: String
  DBSubnetGroupName: String
  DeleteAutomatedBackups: Boolean
  DeletionProtection: Boolean
  Domain: String
  DomainIAMRoleName: String
  EnableCloudwatchLogsExports: 
    - String
  EnableIAMDatabaseAuthentication: Boolean
  EnablePerformanceInsights: Boolean
  Engine: String
  EngineVersion: String
  Iops: Integer
  KmsKeyId: String
  LicenseModel: String
  MasterUsername: String
  MasterUserPassword: String
  MaxAllocatedStorage: Integer
  MonitoringInterval: Integer
  MonitoringRoleArn: String
  MultiAZ: Boolean
  OptionGroupName: String
  PerformanceInsightsKMSKeyId: String
  PerformanceInsightsRetentionPeriod: Integer
  Port: String
  PreferredBackupWindow: String
  PreferredMaintenanceWindow: String
  ProcessorFeatures: 
    - ProcessorFeature
  PromotionTier: Integer
  PubliclyAccessible: Boolean
  SourceDBInstanceIdentifier: String
  SourceRegion: String
  StorageEncrypted: Boolean
  StorageType: String
  Tags: 
    - Tag
  Timezone: String
  UseDefaultProcessorFeatures: Boolean
  VPCSecurityGroups: 
    - String

Related terms[edit]

See also[edit]

Advertising: